Index: src/ic/ppc/handler-compiler-ppc.cc |
diff --git a/src/ic/ppc/handler-compiler-ppc.cc b/src/ic/ppc/handler-compiler-ppc.cc |
index 48a905793bfb0f6dc2b757e967e9443d460b5dd5..cb73c1725dde9cefe47e90c3254de6780c13d1b9 100644 |
--- a/src/ic/ppc/handler-compiler-ppc.cc |
+++ b/src/ic/ppc/handler-compiler-ppc.cc |
@@ -169,11 +169,7 @@ void PropertyHandlerCompiler::GenerateDictionaryNegativeLookup( |
void NamedLoadHandlerCompiler::GenerateDirectLoadGlobalFunctionPrototype( |
MacroAssembler* masm, int index, Register result, Label* miss) { |
- const int offset = Context::SlotOffset(Context::GLOBAL_OBJECT_INDEX); |
- __ LoadP(result, MemOperand(cp, offset)); |
- __ LoadP(result, |
- FieldMemOperand(result, JSGlobalObject::kNativeContextOffset)); |
- __ LoadP(result, MemOperand(result, Context::SlotOffset(index))); |
+ __ LoadNativeContextSlot(index, result); |
// Load its initial map. The global functions all have initial maps. |
__ LoadP(result, |
FieldMemOperand(result, JSFunction::kPrototypeOrInitialMapOffset)); |