< prev index next >

hotspot/src/share/vm/runtime/synchronizer.cpp

Print this page
rev 7654 : 8054494: Remove sun.misc.Unsafe.monitorEnter, monitorExit and tryMonitorEnter
Reviewed-by: dholmes
Contributed-by: paul.sandoz@oracle.com, filipp.zhinkin@gmail.com

@@ -274,22 +274,10 @@
   THREAD->set_current_pending_monitor_is_from_java(false);
   ObjectSynchronizer::inflate(THREAD, obj())->enter(THREAD);
   THREAD->set_current_pending_monitor_is_from_java(true);
 }
 
-// NOTE: must use heavy weight monitor to handle jni monitor enter
-bool ObjectSynchronizer::jni_try_enter(Handle obj, Thread* THREAD) {
-  if (UseBiasedLocking) {
-    BiasedLocking::revoke_and_rebias(obj, false, THREAD);
-    assert(!obj->mark()->has_bias_pattern(), "biases should be revoked by now");
-  }
-
-  ObjectMonitor* monitor = ObjectSynchronizer::inflate_helper(obj());
-  return monitor->try_enter(THREAD);
-}
-
-
 // NOTE: must use heavy weight monitor to handle jni monitor exit
 void ObjectSynchronizer::jni_exit(oop obj, Thread* THREAD) {
   TEVENT(jni_exit);
   if (UseBiasedLocking) {
     Handle h_obj(THREAD, obj);
< prev index next >