RFR: 8016304: ThreadMXBean.getDeadlockedThreads reports bogus deadlocks on JDK 8
Daniel D. Daugherty
daniel.daugherty at oracle.com
Mon Jun 17 08:49:07 PDT 2013
> webrev: http://cr.openjdk.java.net/~sla/8016304/webrev.00/
Thumbs up.
src/share/vm/services/threadService.cpp
Can you add the following comment:
// The setting of the current_pending_monitor field is speculative
// and racy so we need to check to see if the object is actually owned.
above these two lines:
line 330 address currentOwner = (address)waitingToLockMonitor->owner();
line 331 if (currentOwner != NULL) {
Thanks! I couldn't think of a good comment until this AM. Or I'm
delusional and this isn't a good comment. :-)
test/serviceability/threads/TestFalseDeadLock.java
So the test does repro in 5 seconds sometimes. I'm good with that.
Dan
On 6/17/13 9:22 AM, Staffan Larsen wrote:
> Please review this fix. There is a long description in the bug report of the problem and the solution which I will not copy here. I have made the reproducer from the bug into a test which is also included.
>
> webrev: http://cr.openjdk.java.net/~sla/8016304/webrev.00/
> bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=8016304
> jbs: https://jbs.oracle.com/bugs/browse/JDK-8016304
>
> Thanks,
> /Staffan
More information about the serviceability-dev
mailing list