528 // This value is guarded by the Heap_lock |
528 // This value is guarded by the Heap_lock |
529 gc_count = Universe::heap()->total_collections(); |
529 gc_count = Universe::heap()->total_collections(); |
530 full_gc_count = Universe::heap()->total_full_collections(); |
530 full_gc_count = Universe::heap()->total_full_collections(); |
531 } |
531 } |
532 |
532 |
|
533 if (GC_locker::should_discard(cause, gc_count)) { |
|
534 return; |
|
535 } |
|
536 |
533 VM_ParallelGCSystemGC op(gc_count, full_gc_count, cause); |
537 VM_ParallelGCSystemGC op(gc_count, full_gc_count, cause); |
534 VMThread::execute(&op); |
538 VMThread::execute(&op); |
535 } |
539 } |
536 |
540 |
537 void ParallelScavengeHeap::oop_iterate(ExtendedOopClosure* cl) { |
541 void ParallelScavengeHeap::oop_iterate(ExtendedOopClosure* cl) { |