< prev index next >
src/hotspot/share/runtime/objectMonitor.cpp
Print this page
rev 47413 : Introduce SafepointMechanism
rev 47415 : Add Thread Local handshakes and thread local polling
@@ -1281,11 +1281,11 @@
// Drop the lock
OrderAccess::release_store_ptr(&_owner, NULL);
OrderAccess::fence(); // ST _owner vs LD in unpark()
- if (SafepointMechanism::poll()) {
+ if (SafepointMechanism::poll(Self)) {
TEVENT(unpark before SAFEPOINT);
}
DTRACE_MONITOR_PROBE(contended__exit, this, object(), Self);
Trigger->unpark();
@@ -1935,11 +1935,11 @@
// (a) this thread, if unsafe, doesn't delay the safepoint, and (b)
// this thread, if safe, doesn't steal cycles from GC.
// This is in keeping with the "no loitering in runtime" rule.
// We periodically check to see if there's a safepoint pending.
if ((ctr & 0xFF) == 0) {
- if (SafepointMechanism::poll()) {
+ if (SafepointMechanism::poll(Self)) {
TEVENT(Spin: safepoint);
goto Abort; // abrupt spin egress
}
if (Knob_UsePause & 1) SpinPause();
}
< prev index next >