equal
deleted
inserted
replaced
371 // The caller must be able to tolerate spurious returns from raw_wait(). |
371 // The caller must be able to tolerate spurious returns from raw_wait(). |
372 THREAD->_ParkEvent->reset() ; |
372 THREAD->_ParkEvent->reset() ; |
373 OrderAccess::fence() ; |
373 OrderAccess::fence() ; |
374 |
374 |
375 // check interrupt event |
375 // check interrupt event |
376 if (interruptible && Thread::is_interrupted(THREAD, true)) { |
376 if (interruptible) { |
377 return OM_INTERRUPTED; |
377 assert(THREAD->is_Java_thread(), "Only JavaThreads can be interruptible"); |
|
378 JavaThread* jt = (JavaThread*) THREAD; |
|
379 if (jt->is_interrupted(true)) { |
|
380 return OM_INTERRUPTED; |
|
381 } |
378 } |
382 } |
379 |
383 |
380 intptr_t save = _recursions ; |
384 intptr_t save = _recursions ; |
381 _recursions = 0 ; |
385 _recursions = 0 ; |
382 _waiters ++ ; |
386 _waiters ++ ; |
399 jSelf->set_suspend_equivalent() ; |
403 jSelf->set_suspend_equivalent() ; |
400 } |
404 } |
401 } |
405 } |
402 guarantee (THREAD == _owner, "invariant") ; |
406 guarantee (THREAD == _owner, "invariant") ; |
403 |
407 |
404 if (interruptible && Thread::is_interrupted(THREAD, true)) { |
408 if (interruptible) { |
405 return OM_INTERRUPTED; |
409 JavaThread* jt = (JavaThread*) THREAD; |
|
410 if (jt->is_interrupted(true)) { |
|
411 return OM_INTERRUPTED; |
|
412 } |
406 } |
413 } |
407 return OM_OK ; |
414 return OM_OK ; |
408 } |
415 } |
409 |
416 |
410 int JvmtiRawMonitor::raw_notify(TRAPS) { |
417 int JvmtiRawMonitor::raw_notify(TRAPS) { |