changeset 60634:eb4fe525e58e

8252038: G1: Remove unused G1MarkStatsCache::_num_stats Reviewed-by: sjohanss, kbarrett
author tschatzl
date Fri, 21 Aug 2020 11:54:33 +0200
parents d2eafcf20079
children f4d687218bd2
files src/hotspot/share/gc/g1/g1ConcurrentMark.cpp src/hotspot/share/gc/g1/g1ConcurrentMark.hpp src/hotspot/share/gc/g1/g1RegionMarkStatsCache.cpp src/hotspot/share/gc/g1/g1RegionMarkStatsCache.hpp
diffstat 4 files changed, 6 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/src/hotspot/share/gc/g1/g1ConcurrentMark.cpp	Fri Aug 21 11:54:32 2020 +0200
+++ b/src/hotspot/share/gc/g1/g1ConcurrentMark.cpp	Fri Aug 21 11:54:33 2020 +0200
@@ -443,7 +443,7 @@
     task_queue->initialize();
     _task_queues->register_queue(i, task_queue);
 
-    _tasks[i] = new G1CMTask(i, this, task_queue, _region_mark_stats, _g1h->max_regions());
+    _tasks[i] = new G1CMTask(i, this, task_queue, _region_mark_stats);
 
     _accum_task_vtime[i] = 0.0;
   }
@@ -2814,15 +2814,14 @@
 G1CMTask::G1CMTask(uint worker_id,
                    G1ConcurrentMark* cm,
                    G1CMTaskQueue* task_queue,
-                   G1RegionMarkStats* mark_stats,
-                   uint max_regions) :
+                   G1RegionMarkStats* mark_stats) :
   _objArray_processor(this),
   _worker_id(worker_id),
   _g1h(G1CollectedHeap::heap()),
   _cm(cm),
   _next_mark_bitmap(NULL),
   _task_queue(task_queue),
-  _mark_stats_cache(mark_stats, max_regions, RegionMarkStatsCacheSize),
+  _mark_stats_cache(mark_stats, RegionMarkStatsCacheSize),
   _calls(0),
   _time_target_ms(0.0),
   _start_time_ms(0.0),
--- a/src/hotspot/share/gc/g1/g1ConcurrentMark.hpp	Fri Aug 21 11:54:32 2020 +0200
+++ b/src/hotspot/share/gc/g1/g1ConcurrentMark.hpp	Fri Aug 21 11:54:33 2020 +0200
@@ -818,8 +818,7 @@
   G1CMTask(uint worker_id,
            G1ConcurrentMark *cm,
            G1CMTaskQueue* task_queue,
-           G1RegionMarkStats* mark_stats,
-           uint max_regions);
+           G1RegionMarkStats* mark_stats);
 
   inline void update_liveness(oop const obj, size_t const obj_size);
 
--- a/src/hotspot/share/gc/g1/g1RegionMarkStatsCache.cpp	Fri Aug 21 11:54:32 2020 +0200
+++ b/src/hotspot/share/gc/g1/g1RegionMarkStatsCache.cpp	Fri Aug 21 11:54:33 2020 +0200
@@ -27,9 +27,8 @@
 #include "memory/allocation.inline.hpp"
 #include "utilities/powerOfTwo.hpp"
 
-G1RegionMarkStatsCache::G1RegionMarkStatsCache(G1RegionMarkStats* target, uint max_regions, uint num_cache_entries) :
+G1RegionMarkStatsCache::G1RegionMarkStatsCache(G1RegionMarkStats* target, uint num_cache_entries) :
   _target(target),
-  _num_stats(max_regions),
   _cache(NULL),
   _num_cache_entries(num_cache_entries),
   _cache_hits(0),
--- a/src/hotspot/share/gc/g1/g1RegionMarkStatsCache.hpp	Fri Aug 21 11:54:32 2020 +0200
+++ b/src/hotspot/share/gc/g1/g1RegionMarkStatsCache.hpp	Fri Aug 21 11:54:33 2020 +0200
@@ -63,8 +63,6 @@
 private:
   // The array of statistics entries to evict to; the global array.
   G1RegionMarkStats* _target;
-  // Number of entries in the eviction target.
-  uint _num_stats;
 
   // An entry of the statistics cache.
   struct G1RegionMarkStatsCacheEntry {
@@ -100,7 +98,7 @@
 
   G1RegionMarkStatsCacheEntry* find_for_add(uint region_idx);
 public:
-  G1RegionMarkStatsCache(G1RegionMarkStats* target, uint max_regions, uint num_cache_entries);
+  G1RegionMarkStatsCache(G1RegionMarkStats* target, uint num_cache_entries);
 
   ~G1RegionMarkStatsCache();