Index: src/full-codegen/arm/full-codegen-arm.cc |
diff --git a/src/full-codegen/arm/full-codegen-arm.cc b/src/full-codegen/arm/full-codegen-arm.cc |
index 705e2b79a76456dcf466d4754d4fa267bc4403dd..16bd8bc27d2109dcbfb63e546978829f4c31ba00 100644 |
--- a/src/full-codegen/arm/full-codegen-arm.cc |
+++ b/src/full-codegen/arm/full-codegen-arm.cc |
@@ -1414,7 +1414,6 @@ void FullCodeGenerator::EmitGlobalVariableLoad(VariableProxy* proxy, |
if (var->IsGlobalSlot()) { |
DCHECK(var->index() > 0); |
DCHECK(var->IsStaticGlobalObjectProperty()); |
- // Each var occupies two slots in the context: for reads and writes. |
const int slot = var->index(); |
const int depth = scope()->ContextChainLength(var->scope()); |
if (depth <= LoadGlobalViaContextStub::kMaximumDepth) { |
@@ -2713,8 +2712,7 @@ void FullCodeGenerator::EmitVariableAssignment(Variable* var, Token::Value op, |
// Global var, const, or let. |
DCHECK(var->index() > 0); |
DCHECK(var->IsStaticGlobalObjectProperty()); |
- // Each var occupies two slots in the context: for reads and writes. |
- const int slot = var->index() + 1; |
+ const int slot = var->index(); |
const int depth = scope()->ContextChainLength(var->scope()); |
if (depth <= StoreGlobalViaContextStub::kMaximumDepth) { |
__ mov(StoreGlobalViaContextDescriptor::SlotRegister(), Operand(slot)); |