< prev index next >

src/hotspot/cpu/x86/interp_masm_x86.cpp

Print this page
*** 1188,13 ***
      if (LockingMode == LM_LIGHTWEIGHT) {
  #ifdef _LP64
        const Register thread = r15_thread;
  #else
        const Register thread = lock_reg;
-       get_thread(thread);
  #endif
!       lightweight_lock(obj_reg, swap_reg, thread, tmp_reg, slow_case);
      } else if (LockingMode == LM_LEGACY) {
        // Load immediate 1 into swap_reg %rax
        movl(swap_reg, 1);
  
        // Load (object->mark() | 1) into swap_reg %rax
--- 1188,12 ---
      if (LockingMode == LM_LIGHTWEIGHT) {
  #ifdef _LP64
        const Register thread = r15_thread;
  #else
        const Register thread = lock_reg;
  #endif
!       lightweight_lock(lock_reg, obj_reg, swap_reg, thread, tmp_reg, slow_case);
      } else if (LockingMode == LM_LEGACY) {
        // Load immediate 1 into swap_reg %rax
        movl(swap_reg, 1);
  
        // Load (object->mark() | 1) into swap_reg %rax

*** 1253,10 ***
--- 1252,11 ---
  
      bind(slow_case);
  
      // Call the runtime routine for slow case
      if (LockingMode == LM_LIGHTWEIGHT) {
+       // TODO[OMWorld]: Clean this monitorenter_obj up. We still want to use the lock_reg for lightweight
        call_VM(noreg,
                CAST_FROM_FN_PTR(address, InterpreterRuntime::monitorenter_obj),
                obj_reg);
      } else {
        call_VM(noreg,
< prev index next >