7020042: G1: Partially remove fix for 6994628
authorjohnc
Fri, 18 Feb 2011 10:07:34 -0800
changeset 8931 8e2b610bc48f
parent 8930 52368505ee8e
child 8932 a676b28e2093
child 9175 80221fe09772
7020042: G1: Partially remove fix for 6994628 Summary: Disable reference discovery and processing during concurrent marking by disabling fix for 6994628. Reviewed-by: tonyp, ysr
hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp
hotspot/src/share/vm/gc_implementation/g1/g1_globals.hpp
--- a/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp	Mon Apr 04 14:23:17 2011 -0400
+++ b/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp	Fri Feb 18 10:07:34 2011 -0800
@@ -3203,8 +3203,12 @@
                CMTask* task)
     : _g1h(g1h), _cm(cm), _task(task)
   {
-    _ref_processor = g1h->ref_processor();
-    assert(_ref_processor != NULL, "should not be NULL");
+    assert(_ref_processor == NULL, "should be initialized to NULL");
+
+    if (G1UseConcMarkReferenceProcessing) {
+      _ref_processor = g1h->ref_processor();
+      assert(_ref_processor != NULL, "should not be NULL");
+    }
   }
 };
 
--- a/hotspot/src/share/vm/gc_implementation/g1/g1_globals.hpp	Mon Apr 04 14:23:17 2011 -0400
+++ b/hotspot/src/share/vm/gc_implementation/g1/g1_globals.hpp	Fri Feb 18 10:07:34 2011 -0800
@@ -89,6 +89,11 @@
           "The number of discovered reference objects to process before "   \
           "draining concurrent marking work queues.")                       \
                                                                             \
+  experimental(bool, G1UseConcMarkReferenceProcessing, false,               \
+          "If true, enable reference discovery during concurrent "          \
+          "marking and reference processing at the end of remark "          \
+          "(unsafe).")                                                      \
+                                                                            \
   develop(bool, G1SATBBarrierPrintNullPreVals, false,                       \
           "If true, count frac of ptr writes with null pre-vals.")          \
                                                                             \