| Index: src/mips/code-stubs-mips.cc
|
| diff --git a/src/mips/code-stubs-mips.cc b/src/mips/code-stubs-mips.cc
|
| index 11b14be6671a47c84e0356a20bf4722407d10fd6..3053cb769f0c1046142f1421b3ec15c91039a111 100644
|
| --- a/src/mips/code-stubs-mips.cc
|
| +++ b/src/mips/code-stubs-mips.cc
|
| @@ -2524,30 +2524,9 @@ static void EmitContinueIfStrictOrNative(MacroAssembler* masm, Label* cont) {
|
| }
|
|
|
|
|
| -static void EmitSlowCase(MacroAssembler* masm,
|
| - int argc,
|
| - Label* non_function) {
|
| - // Check for function proxy.
|
| - __ Branch(non_function, ne, t0, Operand(JS_FUNCTION_PROXY_TYPE));
|
| - __ push(a1); // put proxy as additional argument
|
| - __ li(a0, Operand(argc + 1, RelocInfo::NONE32));
|
| - __ mov(a2, zero_reg);
|
| - __ GetBuiltinFunction(a1, Context::CALL_FUNCTION_PROXY_BUILTIN_INDEX);
|
| - {
|
| - Handle<Code> adaptor =
|
| - masm->isolate()->builtins()->ArgumentsAdaptorTrampoline();
|
| - __ Jump(adaptor, RelocInfo::CODE_TARGET);
|
| - }
|
| -
|
| - // CALL_NON_FUNCTION expects the non-function callee as receiver (instead
|
| - // of the original receiver from the call site).
|
| - __ bind(non_function);
|
| - __ sw(a1, MemOperand(sp, argc * kPointerSize));
|
| - __ li(a0, Operand(argc)); // Set up the number of arguments.
|
| - __ mov(a2, zero_reg);
|
| - __ GetBuiltinFunction(a1, Context::CALL_NON_FUNCTION_BUILTIN_INDEX);
|
| - __ Jump(masm->isolate()->builtins()->ArgumentsAdaptorTrampoline(),
|
| - RelocInfo::CODE_TARGET);
|
| +static void EmitSlowCase(MacroAssembler* masm, int argc) {
|
| + __ li(a0, Operand(argc));
|
| + __ Jump(masm->isolate()->builtins()->Call(), RelocInfo::CODE_TARGET);
|
| }
|
|
|
|
|
| @@ -2569,12 +2548,12 @@ static void CallFunctionNoFeedback(MacroAssembler* masm,
|
| int argc, bool needs_checks,
|
| bool call_as_method) {
|
| // a1 : the function to call
|
| - Label slow, non_function, wrap, cont;
|
| + Label slow, wrap, cont;
|
|
|
| if (needs_checks) {
|
| // Check that the function is really a JavaScript function.
|
| // a1: pushed function (to be verified)
|
| - __ JumpIfSmi(a1, &non_function);
|
| + __ JumpIfSmi(a1, &slow);
|
|
|
| // Goto slow case if we do not have a function.
|
| __ GetObjectType(a1, t0, t0);
|
| @@ -2609,7 +2588,7 @@ static void CallFunctionNoFeedback(MacroAssembler* masm,
|
| if (needs_checks) {
|
| // Slow-case: Non-function called.
|
| __ bind(&slow);
|
| - EmitSlowCase(masm, argc, &non_function);
|
| + EmitSlowCase(masm, argc);
|
| }
|
|
|
| if (call_as_method) {
|
| @@ -2743,13 +2722,8 @@ void CallIC_ArrayStub::Generate(MacroAssembler* masm) {
|
| GenerateMiss(masm);
|
|
|
| // The slow case, we need this no matter what to complete a call after a miss.
|
| - CallFunctionNoFeedback(masm,
|
| - arg_count(),
|
| - true,
|
| - CallAsMethod());
|
| -
|
| - // Unreachable.
|
| - __ stop("Unexpected code address");
|
| + __ li(a0, Operand(arg_count()));
|
| + __ Jump(masm->isolate()->builtins()->Call(), RelocInfo::CODE_TARGET);
|
| }
|
|
|
|
|
| @@ -2762,7 +2736,7 @@ void CallICStub::Generate(MacroAssembler* masm) {
|
| const int generic_offset =
|
| FixedArray::OffsetOfElementAt(TypeFeedbackVector::kGenericCountIndex);
|
| Label extra_checks_or_miss, slow_start;
|
| - Label slow, non_function, wrap, cont;
|
| + Label slow, wrap, cont;
|
| Label have_js_function;
|
| int argc = arg_count();
|
| ParameterCount actual(argc);
|
| @@ -2816,7 +2790,7 @@ void CallICStub::Generate(MacroAssembler* masm) {
|
| __ InvokeFunction(a1, actual, JUMP_FUNCTION, NullCallWrapper());
|
|
|
| __ bind(&slow);
|
| - EmitSlowCase(masm, argc, &non_function);
|
| + EmitSlowCase(masm, argc);
|
|
|
| if (CallAsMethod()) {
|
| __ bind(&wrap);
|
| @@ -2904,7 +2878,7 @@ void CallICStub::Generate(MacroAssembler* masm) {
|
| __ bind(&slow_start);
|
| // Check that the function is really a JavaScript function.
|
| // r1: pushed function (to be verified)
|
| - __ JumpIfSmi(a1, &non_function);
|
| + __ JumpIfSmi(a1, &slow);
|
|
|
| // Goto slow case if we do not have a function.
|
| __ GetObjectType(a1, t0, t0);
|
|
|