Mercurial > hg > graal-compiler
diff src/cpu/x86/vm/c1_MacroAssembler_x86.cpp @ 7126:ce248dc0a656
removed all Graal modifications to ci and c1
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Mon, 03 Dec 2012 17:54:05 +0100 |
parents | e522a00b91aa |
children | cefad50507d8 |
line wrap: on
line diff
--- a/src/cpu/x86/vm/c1_MacroAssembler_x86.cpp Mon Dec 03 15:32:17 2012 +0100 +++ b/src/cpu/x86/vm/c1_MacroAssembler_x86.cpp Mon Dec 03 17:54:05 2012 +0100 @@ -35,7 +35,7 @@ #include "runtime/os.hpp" #include "runtime/stubRoutines.hpp" -int C1_MacroAssembler::lock_object(Register hdr, Register obj, Register disp_hdr, Register scratch, Label& slow_case, bool use_basic_object_lock) { +int C1_MacroAssembler::lock_object(Register hdr, Register obj, Register disp_hdr, Register scratch, Label& slow_case) { const int aligned_mask = BytesPerWord -1; const int hdr_offset = oopDesc::mark_offset_in_bytes(); assert(hdr == rax, "hdr must be rax, for the cmpxchg instruction"); @@ -45,10 +45,8 @@ verify_oop(obj); - if (use_basic_object_lock) { - // save object being locked into the BasicObjectLock - movptr(Address(disp_hdr, BasicObjectLock::obj_offset_in_bytes()), obj); - } + // save object being locked into the BasicObjectLock + movptr(Address(disp_hdr, BasicObjectLock::obj_offset_in_bytes()), obj); if (UseBiasedLocking) { assert(scratch != noreg, "should have scratch register at this point"); @@ -100,7 +98,7 @@ } -void C1_MacroAssembler::unlock_object(Register hdr, Register obj, Register disp_hdr, Label& slow_case, bool use_basic_object_lock) { +void C1_MacroAssembler::unlock_object(Register hdr, Register obj, Register disp_hdr, Label& slow_case) { const int aligned_mask = BytesPerWord -1; const int hdr_offset = oopDesc::mark_offset_in_bytes(); assert(disp_hdr == rax, "disp_hdr must be rax, for the cmpxchg instruction"); @@ -108,10 +106,8 @@ Label done; if (UseBiasedLocking) { - if (use_basic_object_lock) { - // load object - movptr(obj, Address(disp_hdr, BasicObjectLock::obj_offset_in_bytes())); - } + // load object + movptr(obj, Address(disp_hdr, BasicObjectLock::obj_offset_in_bytes())); biased_locking_exit(obj, hdr, done); } @@ -122,10 +118,8 @@ // if we had recursive locking, we are done jcc(Assembler::zero, done); if (!UseBiasedLocking) { - if (use_basic_object_lock) { - // load object - movptr(obj, Address(disp_hdr, BasicObjectLock::obj_offset_in_bytes())); - } + // load object + movptr(obj, Address(disp_hdr, BasicObjectLock::obj_offset_in_bytes())); } verify_oop(obj); // test if object header is pointing to the displaced header, and if so, restore @@ -290,13 +284,10 @@ } } -#ifndef GRAAL - // TODO(thomaswue): Check how we can access the flag without a ciEnv object. if (CURRENT_ENV->dtrace_alloc_probes()) { assert(obj == rax, "must be"); call(RuntimeAddress(Runtime1::entry_for(Runtime1::dtrace_object_alloc_id))); } -#endif verify_oop(obj); } @@ -326,14 +317,10 @@ const Register len_zero = len; initialize_body(obj, arr_size, header_size * BytesPerWord, len_zero); - -#ifndef GRAAL - // TODO(thomaswue): Check how we can access the flag without a ciEnv object. if (CURRENT_ENV->dtrace_alloc_probes()) { assert(obj == rax, "must be"); call(RuntimeAddress(Runtime1::entry_for(Runtime1::dtrace_object_alloc_id))); } -#endif verify_oop(obj); }