mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-19 02:24:40 +02:00
8252981: ObjectMonitor::object() cleanup changes extracted from JDK-8247281
Co-authored-by: Erik Österlund <erik.osterlund@oracle.com> Co-authored-by: Daniel Daugherty <daniel.daugherty@oracle.com> Reviewed-by: rehn, coleenp, eosterlund
This commit is contained in:
parent
040c8f58e5
commit
e7a1b9bf81
8 changed files with 44 additions and 44 deletions
|
@ -229,12 +229,12 @@ Handle ThreadService::get_current_contended_monitor(JavaThread* thread) {
|
|||
oop obj = NULL;
|
||||
if (wait_obj != NULL) {
|
||||
// thread is doing an Object.wait() call
|
||||
obj = (oop) wait_obj->object();
|
||||
obj = wait_obj->object();
|
||||
} else {
|
||||
ObjectMonitor *enter_obj = thread->current_pending_monitor();
|
||||
if (enter_obj != NULL) {
|
||||
// thread is trying to enter() an ObjectMonitor.
|
||||
obj = (oop) enter_obj->object();
|
||||
obj = enter_obj->object();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -625,7 +625,7 @@ public:
|
|||
}
|
||||
void do_monitor(ObjectMonitor* mid) {
|
||||
if (mid->owner() == _thread) {
|
||||
oop object = (oop) mid->object();
|
||||
oop object = mid->object();
|
||||
if (!_stack_trace->is_owned_monitor_on_stack(object)) {
|
||||
_stack_trace->add_jni_locked_monitor(object);
|
||||
}
|
||||
|
@ -997,7 +997,7 @@ void DeadlockCycle::print_on_with(ThreadsList * t_list, outputStream* st) const
|
|||
|
||||
if (waitingToLockMonitor != NULL) {
|
||||
st->print(" waiting to lock monitor " INTPTR_FORMAT, p2i(waitingToLockMonitor));
|
||||
oop obj = (oop)waitingToLockMonitor->object();
|
||||
oop obj = waitingToLockMonitor->object();
|
||||
st->print(" (object " INTPTR_FORMAT ", a %s)", p2i(obj),
|
||||
obj->klass()->external_name());
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue