--- old/src/share/vm/gc/g1/g1CollectedHeap.cpp 2015-11-24 10:07:41.901848672 +0100 +++ new/src/share/vm/gc/g1/g1CollectedHeap.cpp 2015-11-24 10:07:41.789844338 +0100 @@ -2250,7 +2250,7 @@ return blk.result(); } -bool G1CollectedHeap::user_requested_concurrent_full_gc(GCCause::Cause cause) { +bool G1CollectedHeap::is_user_requested_concurrent_full_gc(GCCause::Cause cause) { switch (cause) { case GCCause::_java_lang_system_gc: return ExplicitGCInvokesConcurrent; case GCCause::_dcmd_gc_run: return ExplicitGCInvokesConcurrent; @@ -2264,7 +2264,7 @@ switch (cause) { case GCCause::_gc_locker: return GCLockerInvokesConcurrent; case GCCause::_g1_humongous_allocation: return true; - default: return user_requested_concurrent_full_gc(cause); + default: return is_user_requested_concurrent_full_gc(cause); } } --- old/src/share/vm/gc/g1/g1CollectedHeap.hpp 2015-11-24 10:07:42.605875911 +0100 +++ new/src/share/vm/gc/g1/g1CollectedHeap.hpp 2015-11-24 10:07:42.477870959 +0100 @@ -245,8 +245,6 @@ // explicitly started if: // (a) cause == _gc_locker and +GCLockerInvokesConcurrent, or // (b) cause == _g1_humongous_allocation - // These are defined in user_requested_concurrent_full_gc() because - // these sometimes need to be treated differently: // (c) cause == _java_lang_system_gc and +ExplicitGCInvokesConcurrent. // (d) cause == _dcmd_gc_run and +ExplicitGCInvokesConcurrent. // (e) cause == _update_allocation_context_stats_inc @@ -580,10 +578,7 @@ _in_cset_fast_test.clear(); } - // A complement to should_do_concurrent_full_gc. GCs caused - // by a user sometimes needs to be treated differently - // from those caused by the VM. - bool user_requested_concurrent_full_gc(GCCause::Cause cause); + bool is_user_requested_concurrent_full_gc(GCCause::Cause cause); // This is called at the start of either a concurrent cycle or a Full // GC to update the number of old marking cycles started. --- old/src/share/vm/gc/g1/g1CollectorPolicy.cpp 2015-11-24 10:07:43.245900675 +0100 +++ new/src/share/vm/gc/g1/g1CollectorPolicy.cpp 2015-11-24 10:07:43.133896341 +0100 @@ -1647,9 +1647,9 @@ ergo_verbose0(ErgoConcCycles, "initiate concurrent cycle", ergo_format_reason("concurrent cycle initiation requested")); - } else if (_g1->user_requested_concurrent_full_gc(_g1->gc_cause())) { - // Initiate a user requested initial mark and update the collector state to - // reflect this. + } else if (_g1->is_user_requested_concurrent_full_gc(_g1->gc_cause())) { + // Initiate a user requested initial mark. An initial mark must be young only + // GC, so the collector state must be updated to reflect this. collector_state()->set_gcs_are_young(true); collector_state()->set_last_young_gc(false);