Fwd: Patch: Clean up fix for JDK-8047720

Daniel D. Daugherty daniel.daugherty at oracle.com
Tue Feb 3 22:16:47 UTC 2015


Carsten,

I've filed the following new bug to track this potential issue:

JDK-8072439 fix for 8047720 may need more work
https://bugs.openjdk.java.net/browse/JDK-8072439

Dan

On 2/3/15 12:00 PM, Carsten Varming wrote:
> Greetings all,
>
> I was recently introduced to the deadlock described in JDK-8047720 and 
> fixed in JDK9. The fix seems a little messy to me, and it looks like 
> it left some very short races in the code. So I decided to clean up 
> the code. See attached diff.
>
> The change takes a step back and acquires PeriodicTask_lock in 
> WatcherThread::stop (like before the fix in JDK9), but this time 
> safepoints are allowed to proceed when acquiring PeriodicTask_lock, 
> preventing the deadlock.
>
> Let me know what you think,
> Carsten
>



More information about the serviceability-dev mailing list