Index: src/interpreter/interpreter.cc |
diff --git a/src/interpreter/interpreter.cc b/src/interpreter/interpreter.cc |
index ef7735e38ccbe00521091c3aee72ba62366b7b86..48b0f3ad12e74b18edb18e48621dce2e9911ad76 100644 |
--- a/src/interpreter/interpreter.cc |
+++ b/src/interpreter/interpreter.cc |
@@ -216,7 +216,9 @@ void Interpreter::DoLoadGlobal(Callable ic, |
compiler::InterpreterAssembler* assembler) { |
// Get the global object. |
Node* context = __ GetContext(); |
- Node* global = __ LoadContextSlot(context, Context::GLOBAL_OBJECT_INDEX); |
+ Node* native_context = |
+ __ LoadContextSlot(context, Context::NATIVE_CONTEXT_INDEX); |
+ Node* global = __ LoadContextSlot(native_context, Context::EXTENSION_INDEX); |
// Load the global via the LoadIC. |
Node* code_target = __ HeapConstant(ic.code()); |
@@ -330,7 +332,9 @@ void Interpreter::DoStoreGlobal(Callable ic, |
compiler::InterpreterAssembler* assembler) { |
// Get the global object. |
Node* context = __ GetContext(); |
- Node* global = __ LoadContextSlot(context, Context::GLOBAL_OBJECT_INDEX); |
+ Node* native_context = |
+ __ LoadContextSlot(context, Context::NATIVE_CONTEXT_INDEX); |
+ Node* global = __ LoadContextSlot(native_context, Context::EXTENSION_INDEX); |
// Store the global via the StoreIC. |
Node* code_target = __ HeapConstant(ic.code()); |
@@ -952,9 +956,8 @@ void Interpreter::DoCallJSRuntime(compiler::InterpreterAssembler* assembler) { |
// Get the function to call from the native context. |
Node* context = __ GetContext(); |
- Node* global = __ LoadContextSlot(context, Context::GLOBAL_OBJECT_INDEX); |
Node* native_context = |
- __ LoadObjectField(global, JSGlobalObject::kNativeContextOffset); |
+ __ LoadContextSlot(context, Context::NATIVE_CONTEXT_INDEX); |
Node* function = __ LoadContextSlot(native_context, context_index); |
// Call the function. |