| Index: src/ia32/macro-assembler-ia32.cc
|
| diff --git a/src/ia32/macro-assembler-ia32.cc b/src/ia32/macro-assembler-ia32.cc
|
| index 8219d30f71cf1831fe0ac22b453ecc9590aafea6..8f91cc87dbd0b4cfe616a9d75f3177907ffb4659 100644
|
| --- a/src/ia32/macro-assembler-ia32.cc
|
| +++ b/src/ia32/macro-assembler-ia32.cc
|
| @@ -2409,12 +2409,18 @@ void MacroAssembler::LoadInitialArrayMap(
|
| }
|
|
|
|
|
| -void MacroAssembler::LoadGlobalFunction(int index, Register function) {
|
| +void MacroAssembler::LoadGlobalContext(Register global_context) {
|
| // Load the global or builtins object from the current context.
|
| - mov(function,
|
| + mov(global_context,
|
| Operand(esi, Context::SlotOffset(Context::GLOBAL_OBJECT_INDEX)));
|
| // Load the native context from the global or builtins object.
|
| - mov(function, FieldOperand(function, GlobalObject::kNativeContextOffset));
|
| + mov(global_context,
|
| + FieldOperand(global_context, GlobalObject::kNativeContextOffset));
|
| +}
|
| +
|
| +
|
| +void MacroAssembler::LoadGlobalFunction(int index, Register function) {
|
| + LoadGlobalContext(function);
|
| // Load the function from the native context.
|
| mov(function, Operand(function, Context::SlotOffset(index)));
|
| }
|
|
|