./src/share/vm/oops/cpCache.cpp

Print this page
rev 4331 : review #1

@@ -264,11 +264,12 @@
   // Competing writers must acquire exclusive access via a lock.
   // A losing writer waits on the lock until the winner writes f1 and leaves
   // the lock, so that when the losing writer returns, he can use the linked
   // cache entry.
 
-  MonitorLockerEx ml(cpool->lock());
+  oop cplock = cpool->lock();
+  ObjectLocker ol(cplock, Thread::current(), cplock != NULL);
   if (!is_f1_null()) {
     return;
   }
 
   const methodHandle adapter = call_info.resolved_method();