8062206: Remove unusable G1RSLogCheckCardTable command line argument
authorkbarrett
Mon, 27 Oct 2014 17:24:10 -0400
changeset 27635 2cda6d613b7a
parent 27634 e6b8ad4d87ac
child 27636 2d749ba03ff5
child 27677 b1997f2f1b56
8062206: Remove unusable G1RSLogCheckCardTable command line argument Summary: Remove dependent assertion and remove develop option Reviewed-by: jwilhelm, mgerdin, tschatzl
hotspot/src/share/vm/gc_implementation/g1/g1RemSet.cpp
hotspot/src/share/vm/gc_implementation/g1/g1RemSet.hpp
hotspot/src/share/vm/gc_implementation/g1/g1_globals.hpp
--- a/hotspot/src/share/vm/gc_implementation/g1/g1RemSet.cpp	Mon Nov 10 12:13:46 2014 +0100
+++ b/hotspot/src/share/vm/gc_implementation/g1/g1RemSet.cpp	Mon Oct 27 17:24:10 2014 -0400
@@ -97,13 +97,6 @@
   FREE_C_HEAP_ARRAY(OopsInHeapRegionClosure*, _cset_rs_update_cl, mtGC);
 }
 
-void CountNonCleanMemRegionClosure::do_MemRegion(MemRegion mr) {
-  if (_g1->is_in_g1_reserved(mr.start())) {
-    _n += (int) ((mr.byte_size() / CardTableModRefBS::card_size));
-    if (_start_first == NULL) _start_first = mr.start();
-  }
-}
-
 class ScanRSClosure : public HeapRegionClosure {
   size_t _cards_done, _cards;
   G1CollectedHeap* _g1h;
@@ -303,15 +296,6 @@
 
   _g1->iterate_dirty_card_closure(&into_cset_update_rs_cl, into_cset_dcq, false, worker_i);
 
-  // Now there should be no dirty cards.
-  if (G1RSLogCheckCardTable) {
-    CountNonCleanMemRegionClosure cl(_g1);
-    _ct_bs->mod_card_iterate(&cl);
-    // XXX This isn't true any more: keeping cards of young regions
-    // marked dirty broke it.  Need some reasonable fix.
-    guarantee(cl.n() == 0, "Card table should be clean.");
-  }
-
   _g1p->phase_times()->record_update_rs_time(worker_i, (os::elapsedTime() - start) * 1000.0);
 }
 
--- a/hotspot/src/share/vm/gc_implementation/g1/g1RemSet.hpp	Mon Nov 10 12:13:46 2014 +0100
+++ b/hotspot/src/share/vm/gc_implementation/g1/g1RemSet.hpp	Mon Oct 27 17:24:10 2014 -0400
@@ -151,19 +151,6 @@
   }
 };
 
-class CountNonCleanMemRegionClosure: public MemRegionClosure {
-  G1CollectedHeap* _g1;
-  int _n;
-  HeapWord* _start_first;
-public:
-  CountNonCleanMemRegionClosure(G1CollectedHeap* g1) :
-    _g1(g1), _n(0), _start_first(NULL)
-  {}
-  void do_MemRegion(MemRegion mr);
-  int n() { return _n; };
-  HeapWord* start_first() { return _start_first; }
-};
-
 class UpdateRSOopClosure: public ExtendedOopClosure {
   HeapRegion* _from;
   G1RemSet* _rs;
--- a/hotspot/src/share/vm/gc_implementation/g1/g1_globals.hpp	Mon Nov 10 12:13:46 2014 +0100
+++ b/hotspot/src/share/vm/gc_implementation/g1/g1_globals.hpp	Mon Oct 27 17:24:10 2014 -0400
@@ -108,10 +108,6 @@
   develop(bool, G1RSBarrierRegionFilter, true,                              \
           "If true, generate region filtering code in RS barrier")          \
                                                                             \
-  develop(bool, G1RSLogCheckCardTable, false,                               \
-          "If true, verify that no dirty cards remain after RS log "        \
-          "processing.")                                                    \
-                                                                            \
   diagnostic(bool, G1PrintRegionLivenessInfo, false,                        \
             "Prints the liveness information for all regions in the heap "  \
             "at the end of a marking cycle.")                               \