Index: src/arm/lithium-arm.cc |
diff --git a/src/arm/lithium-arm.cc b/src/arm/lithium-arm.cc |
index 417927f51ec127ab36bc33e3175fde79f94b9c6b..b6531ca5b36612844d90931487b449c188a9c97c 100644 |
--- a/src/arm/lithium-arm.cc |
+++ b/src/arm/lithium-arm.cc |
@@ -1861,7 +1861,7 @@ LInstruction* LChunkBuilder::DoLoadKeyedSpecializedArrayElement( |
array_type == kExternalDoubleArray))); |
ASSERT(instr->key()->representation().IsInteger32()); |
LOperand* external_pointer = UseRegister(instr->external_pointer()); |
- LOperand* key = UseRegister(instr->key()); |
+ LOperand* key = UseRegisterOrConstant(instr->key()); |
LLoadKeyedSpecializedArrayElement* result = |
new LLoadKeyedSpecializedArrayElement(external_pointer, key); |
LInstruction* load_instr = DefineAsRegister(result); |
@@ -1919,7 +1919,7 @@ LInstruction* LChunkBuilder::DoStoreKeyedSpecializedArrayElement( |
LOperand* val = val_is_temp_register |
? UseTempRegister(instr->value()) |
: UseRegister(instr->value()); |
- LOperand* key = UseRegister(instr->key()); |
+ LOperand* key = UseRegisterOrConstant(instr->key()); |
return new LStoreKeyedSpecializedArrayElement(external_pointer, |
key, |