src/hotspot/share/aot/aotCompiledMethod.cpp
changeset 59056 15936b142f86
parent 58537 30a9612a657d
child 59290 97d13893ec3c
--- a/src/hotspot/share/aot/aotCompiledMethod.cpp	Wed Nov 13 11:27:50 2019 +0000
+++ b/src/hotspot/share/aot/aotCompiledMethod.cpp	Wed Nov 13 08:23:23 2019 -0500
@@ -160,8 +160,6 @@
 }
 
 bool AOTCompiledMethod::make_not_entrant_helper(int new_state) {
-  // Make sure the method is not flushed in case of a safepoint in code below.
-  methodHandle the_method(method());
   NoSafepointVerifier nsv;
 
   {
@@ -208,10 +206,7 @@
 bool AOTCompiledMethod::make_entrant() {
   assert(!method()->is_old(), "reviving evolved method!");
 
-  // Make sure the method is not flushed in case of a safepoint in code below.
-  methodHandle the_method(method());
   NoSafepointVerifier nsv;
-
   {
     // Enter critical section.  Does not block for safepoint.
     MutexLocker pl(CompiledMethod_lock, Mutex::_no_safepoint_check_flag);