Index: src/compiler/mips/code-generator-mips.cc |
diff --git a/src/compiler/mips/code-generator-mips.cc b/src/compiler/mips/code-generator-mips.cc |
index f4905c9f72ce4a7c1f4acdfab1f3e4397b2725b9..a581ca5c3ae02a6eaa946e3d9258b2aff81a1739 100644 |
--- a/src/compiler/mips/code-generator-mips.cc |
+++ b/src/compiler/mips/code-generator-mips.cc |
@@ -1101,8 +1101,8 @@ void CodeGenerator::AssembleArchBoolean(Instruction* instr, |
DCHECK(instr->arch_opcode() == kMipsCmpS); |
__ cmp(cc, W, kDoubleCompareReg, left, right); |
} |
- __ mfc1(at, kDoubleCompareReg); |
- __ srl(result, at, 31); // Cmp returns all 1s for true. |
+ __ mfc1(result, kDoubleCompareReg); |
+ __ andi(result, result, 1); // Cmp returns all 1's/0's, use only LSB. |
if (!predicate) // Toggle result for not equal. |
__ xori(result, result, 1); |
} |