1.1 --- a/src/share/vm/runtime/objectMonitor.cpp Fri May 30 10:43:51 2014 +0200 1.2 +++ b/src/share/vm/runtime/objectMonitor.cpp Wed Jun 04 06:25:53 2014 -0700 1.3 @@ -418,6 +418,15 @@ 1.4 jt->java_suspend_self(); 1.5 } 1.6 Self->set_current_pending_monitor(NULL); 1.7 + 1.8 + // We cleared the pending monitor info since we've just gotten past 1.9 + // the enter-check-for-suspend dance and we now own the monitor free 1.10 + // and clear, i.e., it is no longer pending. The ThreadBlockInVM 1.11 + // destructor can go to a safepoint at the end of this block. If we 1.12 + // do a thread dump during that safepoint, then this thread will show 1.13 + // as having "-locked" the monitor, but the OS and java.lang.Thread 1.14 + // states will still report that the thread is blocked trying to 1.15 + // acquire it. 1.16 } 1.17 1.18 Atomic::dec_ptr(&_count);