| Index: src/arm/lithium-arm.cc
|
| diff --git a/src/arm/lithium-arm.cc b/src/arm/lithium-arm.cc
|
| index 1ac152d6a7ec605d725dc8c5adfe4d8dbe853d89..643d0ebe606a422998d3c8fc4dee5986b5b2ebac 100644
|
| --- a/src/arm/lithium-arm.cc
|
| +++ b/src/arm/lithium-arm.cc
|
| @@ -1779,11 +1779,12 @@ LInstruction* LChunkBuilder::DoLoadGlobalGeneric(HLoadGlobalGeneric* instr) {
|
|
|
|
|
| LInstruction* LChunkBuilder::DoStoreGlobalCell(HStoreGlobalCell* instr) {
|
| - LOperand* temp = TempRegister();
|
| - LOperand* value = UseTempRegister(instr->value());
|
| - LInstruction* result = new LStoreGlobalCell(value, temp);
|
| - if (instr->RequiresHoleCheck()) result = AssignEnvironment(result);
|
| - return result;
|
| + LOperand* value = UseRegister(instr->value());
|
| + // Use a temp to check the value in the cell in the case where we perform
|
| + // a hole check.
|
| + return instr->RequiresHoleCheck()
|
| + ? AssignEnvironment(new LStoreGlobalCell(value, TempRegister()))
|
| + : new LStoreGlobalCell(value, NULL);
|
| }
|
|
|
|
|
|
|