提交 f6e91700 编写于 作者: D dbuck

8185164: GetOwnedMonitorInfo() returns incorrect owned monitor

Summary: The GetOwnedMonitorInfo() should not return a pending monitor
Reviewed-by: dcubed
上级 8dd54d55
......@@ -381,6 +381,8 @@ void ATTR ObjectMonitor::enter(TRAPS) {
{ // Change java thread status to indicate blocked on monitor enter.
JavaThreadBlockedOnMonitorEnterState jtbmes(jt, this);
Self->set_current_pending_monitor(this);
DTRACE_MONITOR_PROBE(contended__enter, this, object(), jt);
if (JvmtiExport::should_post_monitor_contended_enter()) {
JvmtiExport::post_monitor_contended_enter(jt, this);
......@@ -395,8 +397,6 @@ void ATTR ObjectMonitor::enter(TRAPS) {
OSThreadContendState osts(Self->osthread());
ThreadBlockInVM tbivm(jt);
Self->set_current_pending_monitor(this);
// TODO-FIXME: change the following for(;;) loop to straight-line code.
for (;;) {
jt->set_suspend_equivalent();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册