Mercurial > hg > graal-jvmci-8
diff src/share/vm/gc_implementation/g1/concurrentMarkThread.cpp @ 5963:64bf7c8270cb
7147724: G1: hang in SurrogateLockerThread::manipulatePLL
Summary: Attempting to initiate a marking cycle when allocating a humongous object can, if a marking cycle is successfully initiated by another thread, result in the allocating thread spinning until the marking cycle is complete. Eliminate a deadlock between the main ConcurrentMarkThread, the SurrogateLocker thread, the VM thread, and a mutator thread waiting on the SecondaryFreeList_lock (while free regions are going to become available) by not manipulating the pending list lock during the prologue and epilogue of the cleanup pause.
Reviewed-by: brutisso, jcoomes, tonyp
author | johnc |
---|---|
date | Mon, 12 Mar 2012 14:59:00 -0700 |
parents | eff609af17d7 |
children | 5c86f8211d1e |
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/concurrentMarkThread.cpp Fri Mar 16 16:14:04 2012 +0100 +++ b/src/share/vm/gc_implementation/g1/concurrentMarkThread.cpp Mon Mar 12 14:59:00 2012 -0700 @@ -155,7 +155,7 @@ CMCheckpointRootsFinalClosure final_cl(_cm); sprintf(verbose_str, "GC remark"); - VM_CGC_Operation op(&final_cl, verbose_str); + VM_CGC_Operation op(&final_cl, verbose_str, true /* needs_pll */); VMThread::execute(&op); } if (cm()->restart_for_overflow() && @@ -189,7 +189,7 @@ CMCleanUp cl_cl(_cm); sprintf(verbose_str, "GC cleanup"); - VM_CGC_Operation op(&cl_cl, verbose_str); + VM_CGC_Operation op(&cl_cl, verbose_str, false /* needs_pll */); VMThread::execute(&op); } else { // We don't want to update the marking status if a GC pause