| Index: src/x64/builtins-x64.cc
|
| diff --git a/src/x64/builtins-x64.cc b/src/x64/builtins-x64.cc
|
| index 8e782158cc68120da5ec8195991899564a596281..c8b132105179d3ee51ea6c1f16a30e88117d38bb 100644
|
| --- a/src/x64/builtins-x64.cc
|
| +++ b/src/x64/builtins-x64.cc
|
| @@ -1053,8 +1053,9 @@ void Builtins::Generate_FunctionCall(MacroAssembler* masm) {
|
| __ Integer32ToSmi(rax, rax);
|
| __ Push(rax);
|
|
|
| - __ Push(rbx);
|
| - __ InvokeBuiltin(Builtins::TO_OBJECT, CALL_FUNCTION);
|
| + __ movp(rax, rbx);
|
| + ToObjectStub stub(masm->isolate());
|
| + __ CallStub(&stub);
|
| __ movp(rbx, rax);
|
| __ Set(rdx, 0); // indicate regular JS_FUNCTION
|
|
|
| @@ -1274,8 +1275,9 @@ static void Generate_ApplyHelper(MacroAssembler* masm, bool targetIsArgument) {
|
|
|
| // Convert the receiver to an object.
|
| __ bind(&call_to_object);
|
| - __ Push(rbx);
|
| - __ InvokeBuiltin(Builtins::TO_OBJECT, CALL_FUNCTION);
|
| + __ movp(rax, rbx);
|
| + ToObjectStub stub(masm->isolate());
|
| + __ CallStub(&stub);
|
| __ movp(rbx, rax);
|
| __ jmp(&push_receiver, Label::kNear);
|
|
|
|
|