< prev index next >

src/hotspot/share/gc/parallel/psVMOperations.cpp

Print this page

        

*** 47,76 **** if (_result == NULL && GCLocker::is_active_and_needs_gc()) { set_gc_locked(); } } - static bool is_cause_full(GCCause::Cause cause) { - return (cause != GCCause::_gc_locker) && (cause != GCCause::_wb_young_gc) - DEBUG_ONLY(&& (cause != GCCause::_scavenge_alot)); - } - // Only used for System.gc() calls VM_ParallelGCSystemGC::VM_ParallelGCSystemGC(uint gc_count, uint full_gc_count, GCCause::Cause gc_cause) : ! VM_GC_Operation(gc_count, gc_cause, full_gc_count, is_cause_full(gc_cause)) { } void VM_ParallelGCSystemGC::doit() { SvcGCMarker sgcm(SvcGCMarker::FULL); ParallelScavengeHeap* heap = ParallelScavengeHeap::heap(); GCCauseSetter gccs(heap, _gc_cause); ! if (!_full) { // If (and only if) the scavenge fails, this will invoke a full gc. heap->invoke_scavenge(); } else { heap->do_full_collection(false); } --- 47,72 ---- if (_result == NULL && GCLocker::is_active_and_needs_gc()) { set_gc_locked(); } } // Only used for System.gc() calls VM_ParallelGCSystemGC::VM_ParallelGCSystemGC(uint gc_count, uint full_gc_count, GCCause::Cause gc_cause) : ! VM_GC_Operation(gc_count, gc_cause, full_gc_count, true /* full */) { } void VM_ParallelGCSystemGC::doit() { SvcGCMarker sgcm(SvcGCMarker::FULL); ParallelScavengeHeap* heap = ParallelScavengeHeap::heap(); GCCauseSetter gccs(heap, _gc_cause); ! if (_gc_cause == GCCause::_gc_locker || _gc_cause == GCCause::_wb_young_gc ! DEBUG_ONLY(|| _gc_cause == GCCause::_scavenge_alot)) { // If (and only if) the scavenge fails, this will invoke a full gc. heap->invoke_scavenge(); } else { heap->do_full_collection(false); }
< prev index next >