changeset 54567:224515275cf9

8219718: ZGC: Make nmethod entry barriers and nmethod::is_unloading use ZNMethodDataOops Reviewed-by: pliden, stefank
author eosterlund
date Wed, 17 Apr 2019 12:41:33 +0200
parents 4224f26b2e7f
children b2ed96c35687
files src/hotspot/share/gc/z/zBarrierSetNMethod.cpp src/hotspot/share/gc/z/zUnload.cpp
diffstat 2 files changed, 2 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/src/hotspot/share/gc/z/zBarrierSetNMethod.cpp	Mon Apr 15 06:41:02 2019 -0700
+++ b/src/hotspot/share/gc/z/zBarrierSetNMethod.cpp	Wed Apr 17 12:41:33 2019 +0200
@@ -55,11 +55,7 @@
 
   // Heal oops and disarm
   ZNMethodOopClosure cl;
-  nm->oops_do(&cl);
-  nm->fix_oop_relocations();
-
-  OrderAccess::release();
-
+  ZNMethod::nmethod_oops_do(nm, &cl);
   disarm(nm);
 
   return true;
--- a/src/hotspot/share/gc/z/zUnload.cpp	Mon Apr 15 06:41:02 2019 -0700
+++ b/src/hotspot/share/gc/z/zUnload.cpp	Wed Apr 17 12:41:33 2019 +0200
@@ -71,7 +71,7 @@
     ZReentrantLock* const lock = ZNMethod::lock_for_nmethod(nm);
     ZLocker<ZReentrantLock> locker(lock);
     ZIsUnloadingOopClosure cl;
-    nm->oops_do(&cl, true /* allow_zombie */);
+    ZNMethod::nmethod_oops_do(nm, &cl);
     return cl.is_unloading();
   }
 };