src/hotspot/share/gc/g1/g1YoungRemSetSamplingThread.cpp
changeset 54623 1126f0607c70
parent 54466 58751415d5f8
child 54645 05aaccf7d558
--- a/src/hotspot/share/gc/g1/g1YoungRemSetSamplingThread.cpp	Thu Apr 25 05:54:54 2019 -0700
+++ b/src/hotspot/share/gc/g1/g1YoungRemSetSamplingThread.cpp	Thu Apr 25 10:56:31 2019 -0400
@@ -47,10 +47,10 @@
 }
 
 void G1YoungRemSetSamplingThread::sleep_before_next_cycle() {
-  MutexLockerEx x(&_monitor, Mutex::_no_safepoint_check_flag);
+  MutexLocker x(&_monitor, Mutex::_no_safepoint_check_flag);
   if (!should_terminate()) {
     uintx waitms = G1ConcRefinementServiceIntervalMillis;
-    _monitor.wait(Mutex::_no_safepoint_check_flag, waitms);
+    _monitor.wait_without_safepoint_check(waitms);
   }
 }
 
@@ -124,7 +124,7 @@
 }
 
 void G1YoungRemSetSamplingThread::stop_service() {
-  MutexLockerEx x(&_monitor, Mutex::_no_safepoint_check_flag);
+  MutexLocker x(&_monitor, Mutex::_no_safepoint_check_flag);
   _monitor.notify();
 }