| Index: src/ia32/lithium-codegen-ia32.cc
|
| diff --git a/src/ia32/lithium-codegen-ia32.cc b/src/ia32/lithium-codegen-ia32.cc
|
| index 1a20fc3b6815c1d2c69a0dfdfb2a209e1f2098e4..ade9ee33225559b1ded765bf169b45a9ed6c142c 100644
|
| --- a/src/ia32/lithium-codegen-ia32.cc
|
| +++ b/src/ia32/lithium-codegen-ia32.cc
|
| @@ -3675,10 +3675,7 @@ void LCodeGen::DoWrapReceiver(LWrapReceiver* instr) {
|
| // TODO(kmillikin): We have a hydrogen value for the global object. See
|
| // if it's better to use it than to explicitly fetch it from the context
|
| // here.
|
| - __ mov(receiver, Operand(ebp, StandardFrameConstants::kContextOffset));
|
| - __ mov(receiver, ContextOperand(receiver, Context::GLOBAL_OBJECT_INDEX));
|
| - __ mov(receiver,
|
| - FieldOperand(receiver, JSGlobalObject::kGlobalReceiverOffset));
|
| + CallStubCompiler::FetchGlobalProxy(masm(), receiver, function);
|
| __ bind(&receiver_ok);
|
| }
|
|
|
| @@ -4245,7 +4242,10 @@ void LCodeGen::DoCallFunction(LCallFunction* instr) {
|
| ASSERT(ToRegister(instr->result()).is(eax));
|
|
|
| int arity = instr->arity();
|
| - CallFunctionStub stub(arity, NO_CALL_FUNCTION_FLAGS);
|
| + CallFunctionFlags flags =
|
| + instr->hydrogen()->IsContextualCall() ?
|
| + RECEIVER_IS_IMPLICIT : NO_CALL_FUNCTION_FLAGS;
|
| + CallFunctionStub stub(arity, flags);
|
| if (instr->hydrogen()->IsTailCall()) {
|
| if (NeedsEagerFrame()) __ leave();
|
| __ jmp(stub.GetCode(isolate()), RelocInfo::CODE_TARGET);
|
|
|