| Index: src/ia32/full-codegen-ia32.cc
|
| diff --git a/src/ia32/full-codegen-ia32.cc b/src/ia32/full-codegen-ia32.cc
|
| index 904e99a8d142b406c5f344d9653fcb7850549eb5..cfa4df97c7a4bde2515d5940e2e984feb26d5fd1 100644
|
| --- a/src/ia32/full-codegen-ia32.cc
|
| +++ b/src/ia32/full-codegen-ia32.cc
|
| @@ -1265,9 +1265,9 @@ void FullCodeGenerator::EmitLoadGlobalCheckExtensions(Variable* var,
|
| __ mov(temp, context);
|
| }
|
| __ bind(&next);
|
| - // Terminate at global context.
|
| + // Terminate at native context.
|
| __ cmp(FieldOperand(temp, HeapObject::kMapOffset),
|
| - Immediate(isolate()->factory()->global_context_map()));
|
| + Immediate(isolate()->factory()->native_context_map()));
|
| __ j(equal, &fast, Label::kNear);
|
| // Check that extension is NULL.
|
| __ cmp(ContextOperand(temp, Context::EXTENSION_INDEX), Immediate(0));
|
| @@ -2696,7 +2696,7 @@ void FullCodeGenerator::EmitIsStringWrapperSafeForDefaultValueOf(
|
| __ mov(ecx, FieldOperand(ecx, HeapObject::kMapOffset));
|
| __ mov(edx, Operand(esi, Context::SlotOffset(Context::GLOBAL_INDEX)));
|
| __ mov(edx,
|
| - FieldOperand(edx, GlobalObject::kGlobalContextOffset));
|
| + FieldOperand(edx, GlobalObject::kNativeContextOffset));
|
| __ cmp(ecx,
|
| ContextOperand(edx,
|
| Context::STRING_FUNCTION_PROTOTYPE_MAP_INDEX));
|
| @@ -2972,7 +2972,7 @@ void FullCodeGenerator::EmitRandomHeapNumber(CallRuntime* expr) {
|
|
|
| __ PrepareCallCFunction(1, ebx);
|
| __ mov(eax, ContextOperand(context_register(), Context::GLOBAL_INDEX));
|
| - __ mov(eax, FieldOperand(eax, GlobalObject::kGlobalContextOffset));
|
| + __ mov(eax, FieldOperand(eax, GlobalObject::kNativeContextOffset));
|
| __ mov(Operand(esp, 0), eax);
|
| __ CallCFunction(ExternalReference::random_uint32_function(isolate()), 1);
|
|
|
| @@ -3403,7 +3403,7 @@ void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) {
|
| int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->handle()))->value();
|
|
|
| Handle<FixedArray> jsfunction_result_caches(
|
| - isolate()->global_context()->jsfunction_result_caches());
|
| + isolate()->native_context()->jsfunction_result_caches());
|
| if (jsfunction_result_caches->length() <= cache_id) {
|
| __ Abort("Attempt to use undefined cache.");
|
| __ mov(eax, isolate()->factory()->undefined_value());
|
| @@ -3418,7 +3418,7 @@ void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) {
|
| Register tmp = ecx;
|
| __ mov(cache, ContextOperand(esi, Context::GLOBAL_INDEX));
|
| __ mov(cache,
|
| - FieldOperand(cache, GlobalObject::kGlobalContextOffset));
|
| + FieldOperand(cache, GlobalObject::kNativeContextOffset));
|
| __ mov(cache, ContextOperand(cache, Context::JSFUNCTION_RESULT_CACHES_INDEX));
|
| __ mov(cache,
|
| FieldOperand(cache, FixedArray::OffsetOfElementAt(cache_id)));
|
| @@ -4438,7 +4438,7 @@ void FullCodeGenerator::PushFunctionArgumentForContextAllocation() {
|
| Scope* declaration_scope = scope()->DeclarationScope();
|
| if (declaration_scope->is_global_scope() ||
|
| declaration_scope->is_module_scope()) {
|
| - // Contexts nested in the global context have a canonical empty function
|
| + // Contexts nested in the native context have a canonical empty function
|
| // as their closure, not the anonymous closure containing the global
|
| // code. Pass a smi sentinel and let the runtime look up the empty
|
| // function.
|
|
|