Mercurial > hg > graal-jvmci-8
diff src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp @ 2089:037c727f35fb
7009231: C1: Incorrect CAS code for longs on SPARC 32bit
Summary: Fix CAS of longs on SPARC 32bit and cmove on SPARC 64bit.
Reviewed-by: kvn
author | iveresov |
---|---|
date | Mon, 27 Dec 2010 21:51:31 -0800 |
parents | f95d63e2154a |
children | e1162778c1c8 |
line wrap: on
line diff
--- a/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp Wed Dec 22 02:02:53 2010 -0800 +++ b/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp Mon Dec 27 21:51:31 2010 -0800 @@ -662,7 +662,7 @@ // generate conditional move of boolean result LIR_Opr result = rlock_result(x); - __ cmove(lir_cond_equal, LIR_OprFact::intConst(1), LIR_OprFact::intConst(0), result); + __ cmove(lir_cond_equal, LIR_OprFact::intConst(1), LIR_OprFact::intConst(0), result, T_LONG); } @@ -699,10 +699,10 @@ else { ShouldNotReachHere(); } - // generate conditional move of boolean result LIR_Opr result = rlock_result(x); - __ cmove(lir_cond_equal, LIR_OprFact::intConst(1), LIR_OprFact::intConst(0), result); + __ cmove(lir_cond_equal, LIR_OprFact::intConst(1), LIR_OprFact::intConst(0), + result, as_BasicType(type)); if (type == objectType) { // Write-barrier needed for Object fields. // Precise card mark since could either be object or array post_barrier(addr, val.result());