Index: src/compiler/mips64/code-generator-mips64.cc |
diff --git a/src/compiler/mips64/code-generator-mips64.cc b/src/compiler/mips64/code-generator-mips64.cc |
index 6c0ee1a020ac6e7644c0c0d360278e4bd0156791..5b47b69a4784926103547365489c2649704bb557 100644 |
--- a/src/compiler/mips64/code-generator-mips64.cc |
+++ b/src/compiler/mips64/code-generator-mips64.cc |
@@ -678,7 +678,12 @@ void CodeGenerator::AssembleArchInstruction(Instruction* instr) { |
__ Or(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); |
break; |
case kMips64Nor: |
- __ Nor(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); |
+ if (instr->InputAt(1)->IsRegister()) { |
+ __ Nor(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); |
+ } else { |
+ DCHECK(i.InputOperand(1).immediate() == 0); |
+ __ Nor(i.OutputRegister(), i.InputRegister(0), zero_reg); |
+ } |
break; |
case kMips64Xor: |
__ Xor(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); |