--- old/src/hotspot/share/runtime/interfaceSupport.inline.hpp 2019-08-21 22:08:19.835707930 -0400 +++ new/src/hotspot/share/runtime/interfaceSupport.inline.hpp 2019-08-21 22:08:19.647707936 -0400 @@ -254,9 +254,9 @@ }; // Unlike ThreadBlockInVM, this class is designed to avoid certain deadlock scenarios while making -// transitions inside class Monitor in cases where we need to block for a safepoint or handshake. It +// transitions inside class Mutex in cases where we need to block for a safepoint or handshake. It // receives an extra argument compared to ThreadBlockInVM, the address of a pointer to the monitor we -// are trying to acquire. This will be used to access and release the monitor if needed to avoid +// are trying to acquire. This will be used to access and release the mutex if needed to avoid // said deadlocks. // It works like ThreadBlockInVM but differs from it in two ways: // - When transitioning in (constructor), it checks for safepoints without blocking, i.e., calls @@ -265,18 +265,18 @@ // the monitor that is only partially acquired. class ThreadBlockInVMWithDeadlockCheck : public ThreadStateTransition { private: - Monitor** _in_flight_monitor_adr; + Mutex** _in_flight_monitor_adr; void release_monitor() { assert(_in_flight_monitor_adr != NULL, "_in_flight_monitor_adr should have been set on constructor"); - Monitor* in_flight_monitor = *_in_flight_monitor_adr; + Mutex* in_flight_monitor = *_in_flight_monitor_adr; if (in_flight_monitor != NULL) { in_flight_monitor->release_for_safepoint(); *_in_flight_monitor_adr = NULL; } } public: - ThreadBlockInVMWithDeadlockCheck(JavaThread* thread, Monitor** in_flight_monitor_adr) + ThreadBlockInVMWithDeadlockCheck(JavaThread* thread, Mutex** in_flight_monitor_adr) : ThreadStateTransition(thread), _in_flight_monitor_adr(in_flight_monitor_adr) { // Once we are blocked vm expects stack to be walkable thread->frame_anchor()->make_walkable(thread);