diff --git a/src/x87/builtins-x87.cc b/src/x87/builtins-x87.cc index 56e49b4586..aca76dbb9e 100644 --- a/src/x87/builtins-x87.cc +++ b/src/x87/builtins-x87.cc @@ -732,7 +732,8 @@ static void Generate_InterpreterPushArgs(MacroAssembler* masm, // static void Builtins::Generate_InterpreterPushArgsAndCallImpl( - MacroAssembler* masm, TailCallMode tail_call_mode) { + MacroAssembler* masm, TailCallMode tail_call_mode, + CallableType function_type) { // ----------- S t a t e ------------- // -- eax : the number of arguments (not including the receiver) // -- ebx : the address of the first argument to be pushed. Subsequent @@ -755,9 +756,17 @@ void Builtins::Generate_InterpreterPushArgsAndCallImpl( // Call the target. __ Push(edx); // Re-push return address. - __ Jump(masm->isolate()->builtins()->Call(ConvertReceiverMode::kAny, - tail_call_mode), - RelocInfo::CODE_TARGET); + + if (function_type == CallableType::kJSFunction) { + __ Jump(masm->isolate()->builtins()->CallFunction(ConvertReceiverMode::kAny, + tail_call_mode), + RelocInfo::CODE_TARGET); + } else { + DCHECK_EQ(function_type, CallableType::kAny); + __ Jump(masm->isolate()->builtins()->Call(ConvertReceiverMode::kAny, + tail_call_mode), + RelocInfo::CODE_TARGET); + } }