disable Math.abs(long) intrinsic on 32-bit x86

It never worked and caused the compiler to crash instead due to an
impossible-to-fulfill constraint.
This commit is contained in:
Joel Dice 2010-11-30 11:36:18 -07:00
parent 8de53aeacc
commit 19dca18cd0
2 changed files with 8 additions and 2 deletions

View File

@ -2914,8 +2914,12 @@ class MyArchitecture: public Assembler::Architecture {
break;
case Absolute:
*aTypeMask = (1 << RegisterOperand);
*aRegisterMask = (static_cast<uint64_t>(1) << rax);
if (aSize <= BytesPerWord) {
*aTypeMask = (1 << RegisterOperand);
*aRegisterMask = (static_cast<uint64_t>(1) << rax);
} else {
*thunk = true;
}
break;
case FloatAbsolute:

View File

@ -60,6 +60,8 @@ public class Longs {
}
public static void main(String[] args) throws Exception {
expect(Math.abs(-123L) == 123L);
expect(readLongFrom(new java.io.InputStream() {
int step;