| Index: src/compiler/arm64/code-generator-arm64.cc
|
| diff --git a/src/compiler/arm64/code-generator-arm64.cc b/src/compiler/arm64/code-generator-arm64.cc
|
| index ecdf148cab5c6516d96231a1925ec56f675e322e..478fcfa0ba1680830b21b05c9af233c4b63e2251 100644
|
| --- a/src/compiler/arm64/code-generator-arm64.cc
|
| +++ b/src/compiler/arm64/code-generator-arm64.cc
|
| @@ -624,7 +624,14 @@ void CodeGenerator::AssembleArchInstruction(Instruction* instr) {
|
| __ Tst(i.InputRegister32(0), i.InputOperand32(1));
|
| break;
|
| case kArm64Float64Cmp:
|
| - __ Fcmp(i.InputDoubleRegister(0), i.InputDoubleRegister(1));
|
| + if (instr->InputAt(1)->IsDoubleRegister()) {
|
| + __ Fcmp(i.InputDoubleRegister(0), i.InputDoubleRegister(1));
|
| + } else {
|
| + DCHECK(instr->InputAt(1)->IsImmediate());
|
| + // 0.0 is the only immediate supported by fcmp instructions.
|
| + DCHECK(i.InputDouble(1) == 0.0);
|
| + __ Fcmp(i.InputDoubleRegister(0), i.InputDouble(1));
|
| + }
|
| break;
|
| case kArm64Float64Add:
|
| __ Fadd(i.OutputDoubleRegister(), i.InputDoubleRegister(0),
|
|
|