SUGGESTED FIX
diff -r c81fa70144aa src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp
--- a/src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp Mon Jan 25 18:03:29 2010 -0500
+++ b/src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp Tue Jan 26 01:28:23 2010 -0800
@@ -1004,7 +1004,11 @@ public:
// storage in the heap comes from a young region or not.
// See ReduceInitialCardMarks.
virtual bool can_elide_tlab_store_barriers() const {
- return true;
+ // Temporarily turned off, because of lingering
+ // instabilities related to RICM with G1. In the
+ // interim, the option ReduceInitialCardMarksForG1
+ // below is left solely as a debugging device.
+ return ReduceInitialCardMarksForG1;
}
virtual bool card_mark_must_follow_store() const {
@@ -1026,6 +1030,7 @@ public:
// However, non-generational G1 (-XX:-G1Gen) appears to have
// bit-rotted so was not tested below.
virtual bool can_elide_initializing_store_barrier(oop new_obj) {
+ assert(ReduceInitialCardMarksForG1, "Else cannot be here");
assert(G1Gen || !is_in_young(new_obj),
"Non-generational G1 should never return true below");
return is_in_young(new_obj);
diff -r c81fa70144aa src/share/vm/gc_implementation/g1/g1_globals.hpp
--- a/src/share/vm/gc_implementation/g1/g1_globals.hpp Mon Jan 25 18:03:29 2010 -0500
+++ b/src/share/vm/gc_implementation/g1/g1_globals.hpp Tue Jan 26 01:28:23 2010 -0800
@@ -291,6 +291,10 @@
"a particular entry exceeds this value.") \
\
develop(bool, G1VerifyCTCleanup, false, \
- "Verify card table cleanup.")
+ "Verify card table cleanup.") \
+ \
+ develop(bool, ReduceInitialCardMarksForG1, false, \
+ "When ReduceInitialCardMarks is true, this flag setting " \
+ " controls whether G1 allows the RICM optimization")
G1_FLAGS(DECLARE_DEVELOPER_FLAG, DECLARE_PD_DEVELOPER_FLAG, DECLARE_PRODUCT_FLAG, DECLARE_PD_PRODUCT_FLAG, DECLARE_DIAGNOSTIC_FLAG, DECLARE_EXPERIMENTAL_FLAG, DECLARE_NOTPRODUCT_FLAG, DECLARE_MANAGEABLE_FLAG, DECLARE_PRODUCT_RW_FLAG)
|