diff --git a/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp b/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp index c5385a984b7e28a7ecc6595dd35bea800ed85a7c..2566f3f8227f25e9eb3030778c77e4de38c2791b 100644 --- a/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp +++ b/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp @@ -664,7 +664,7 @@ void LIRGenerator::do_CompareAndSwap(Intrinsic* x, ValueType* type) { // Use temps to avoid kills LIR_Opr t1 = FrameMap::G1_opr; LIR_Opr t2 = FrameMap::G3_opr; - LIR_Opr addr = (type == objectType) ? new_register(T_OBJECT) : new_pointer_register(); + LIR_Opr addr = new_pointer_register(); // get address of field obj.load_item(); diff --git a/src/cpu/x86/vm/c1_CodeStubs_x86.cpp b/src/cpu/x86/vm/c1_CodeStubs_x86.cpp index f5bea330c2fd016cfcaed7d5561905e0fca89695..b6f9eea591be9a15d822f1bfd4cd2af067e80095 100644 --- a/src/cpu/x86/vm/c1_CodeStubs_x86.cpp +++ b/src/cpu/x86/vm/c1_CodeStubs_x86.cpp @@ -499,7 +499,7 @@ void G1PostBarrierStub::emit_code(LIR_Assembler* ce) { Register new_val_reg = new_val()->as_register(); __ cmpptr(new_val_reg, (int32_t) NULL_WORD); __ jcc(Assembler::equal, _continuation); - ce->store_parameter(addr()->as_register(), 0); + ce->store_parameter(addr()->as_pointer_register(), 0); __ call(RuntimeAddress(Runtime1::entry_for(Runtime1::g1_post_barrier_slow_id))); __ jmp(_continuation); } diff --git a/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp b/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp index c9a26e7b1dd2b24a1da5a24d23d7eac64b386b89..dd8bc8d996240711cd7520892ecefb7942174cf1 100644 --- a/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp +++ b/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp @@ -765,7 +765,7 @@ void LIRGenerator::do_CompareAndSwap(Intrinsic* x, ValueType* type) { ShouldNotReachHere(); } - LIR_Opr addr = (type == objectType) ? new_register(T_OBJECT) : new_pointer_register(); + LIR_Opr addr = new_pointer_register(); LIR_Address* a; if(offset.result()->is_constant()) { a = new LIR_Address(obj.result(), diff --git a/src/share/vm/c1/c1_LIRGenerator.cpp b/src/share/vm/c1/c1_LIRGenerator.cpp index dffc85c970d7d4837acc76cd506e975de84f2e7f..332f193e28ee847bd33036d0d135f5c320388f92 100644 --- a/src/share/vm/c1/c1_LIRGenerator.cpp +++ b/src/share/vm/c1/c1_LIRGenerator.cpp @@ -1350,7 +1350,6 @@ void LIRGenerator::G1SATBCardTableModRef_post_barrier(LIR_OprDesc* addr, LIR_Opr addr = ptr; } assert(addr->is_register(), "must be a register at this point"); - assert(addr->type() == T_OBJECT, "addr should point to an object"); LIR_Opr xor_res = new_pointer_register(); LIR_Opr xor_shift_res = new_pointer_register();