< prev index next >

src/hotspot/share/gc/z/zUnload.cpp

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 2018, 2019, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.

@@ -69,11 +69,11 @@
   virtual bool is_unloading(CompiledMethod* method) const {
     nmethod* const nm = method->as_nmethod();
     ZReentrantLock* const lock = ZNMethod::lock_for_nmethod(nm);
     ZLocker<ZReentrantLock> locker(lock);
     ZIsUnloadingOopClosure cl;
-    ZNMethod::nmethod_oops_do(nm, &cl);
+    nm->oops_do(&cl, true /* allow_zombie */);
     return cl.is_unloading();
   }
 };
 
 class ZCompiledICProtectionBehaviour : public CompiledICProtectionBehaviour {

@@ -128,11 +128,11 @@
 void ZUnload::unlink() {
   SuspendibleThreadSetJoiner sts;
   bool unloading_occurred;
 
   {
-    MutexLocker ml(ClassLoaderDataGraph_lock);
+    MutexLockerEx ml(ClassLoaderDataGraph_lock);
     unloading_occurred = SystemDictionary::do_unloading(ZStatPhase::timer());
   }
 
   Klass::clean_weak_klass_links(unloading_occurred);
 
< prev index next >