Index: src/full-codegen/x87/full-codegen-x87.cc |
diff --git a/src/full-codegen/x87/full-codegen-x87.cc b/src/full-codegen/x87/full-codegen-x87.cc |
index 964440227fb7fb76f2021449e24789ae0e133143..bbcf2eb1250e3ef978bb6b2907153b415d3029c9 100644 |
--- a/src/full-codegen/x87/full-codegen-x87.cc |
+++ b/src/full-codegen/x87/full-codegen-x87.cc |
@@ -3235,10 +3235,12 @@ void FullCodeGenerator::EmitCreateIterResultObject(CallRuntime* expr) { |
void FullCodeGenerator::EmitLoadJSRuntimeFunction(CallRuntime* expr) { |
+ // Push function. |
+ __ LoadGlobalFunction(expr->context_index(), eax); |
+ PushOperand(eax); |
+ |
// Push undefined as receiver. |
PushOperand(isolate()->factory()->undefined_value()); |
- |
- __ LoadGlobalFunction(expr->context_index(), eax); |
} |
@@ -3263,10 +3265,6 @@ void FullCodeGenerator::VisitCallRuntime(CallRuntime* expr) { |
Comment cmnt(masm_, "[ CallRuntime"); |
EmitLoadJSRuntimeFunction(expr); |
- // Push the target function under the receiver. |
- PushOperand(Operand(esp, 0)); |
- __ mov(Operand(esp, kPointerSize), eax); |
- |
// Push the arguments ("left-to-right"). |
for (int i = 0; i < arg_count; i++) { |
VisitForStackValue(args->at(i)); |