--- old/src/share/vm/gc_implementation/g1/concurrentMark.cpp 2015-05-12 17:05:53.017224515 -0400 +++ new/src/share/vm/gc_implementation/g1/concurrentMark.cpp 2015-05-12 17:05:52.845214639 -0400 @@ -30,6 +30,7 @@ #include "gc_implementation/g1/concurrentMarkThread.inline.hpp" #include "gc_implementation/g1/g1CollectedHeap.inline.hpp" #include "gc_implementation/g1/g1CollectorPolicy.hpp" +#include "gc_implementation/g1/g1CollectorState.hpp" #include "gc_implementation/g1/g1ErgoVerbose.hpp" #include "gc_implementation/g1/g1Log.hpp" #include "gc_implementation/g1/g1OopClosures.inline.hpp" @@ -176,7 +177,7 @@ // will have them as guarantees at the beginning / end of the bitmap // clearing to get some checking in the product. assert(!_may_yield || _cm->cmThread()->during_cycle(), "invariant"); - assert(!_may_yield || !G1CollectedHeap::heap()->mark_in_progress(), "invariant"); + assert(!_may_yield || !G1CollectedHeap::heap()->collector_state()->mark_in_progress(), "invariant"); } return false; @@ -829,7 +830,7 @@ // marking bitmap and getting it ready for the next cycle. During // this time no other cycle can start. So, let's make sure that this // is the case. - guarantee(!g1h->mark_in_progress(), "invariant"); + guarantee(!g1h->collector_state()->mark_in_progress(), "invariant"); ClearBitmapHRClosure cl(this, _nextMarkBitMap, true /* may_yield */); ParClearNextMarkBitmapTask task(&cl, parallel_marking_threads(), true); @@ -843,7 +844,7 @@ // Repeat the asserts from above. guarantee(cmThread()->during_cycle(), "invariant"); - guarantee(!g1h->mark_in_progress(), "invariant"); + guarantee(!g1h->collector_state()->mark_in_progress(), "invariant"); } class CheckBitmapClearHRClosure : public HeapRegionClosure { @@ -1255,7 +1256,7 @@ // If a full collection has happened, we shouldn't do this. if (has_aborted()) { - g1h->set_marking_complete(); // So bitmap clearing isn't confused + g1h->collector_state()->set_mark_in_progress(false); // So bitmap clearing isn't confused return; } @@ -1916,7 +1917,7 @@ // If a full collection has happened, we shouldn't do this. if (has_aborted()) { - g1h->set_marking_complete(); // So bitmap clearing isn't confused + g1h->collector_state()->set_mark_in_progress(false); // So bitmap clearing isn't confused return; } @@ -1973,7 +1974,7 @@ } size_t start_used_bytes = g1h->used(); - g1h->set_marking_complete(); + g1h->collector_state()->set_mark_in_progress(false); double count_end = os::elapsedTime(); double this_final_counting_time = (count_end - start); @@ -2805,7 +2806,7 @@ void ConcurrentMark::verify_no_cset_oops() { assert(SafepointSynchronize::is_at_safepoint(), "should be at a safepoint"); - if (!G1CollectedHeap::heap()->mark_in_progress()) { + if (!G1CollectedHeap::heap()->collector_state()->mark_in_progress()) { return; }