| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #if V8_TARGET_ARCH_MIPS | 5 #if V8_TARGET_ARCH_MIPS |
| 6 | 6 |
| 7 #include "src/codegen.h" | 7 #include "src/codegen.h" |
| 8 #include "src/debug/debug.h" | 8 #include "src/debug/debug.h" |
| 9 #include "src/deoptimizer.h" | 9 #include "src/deoptimizer.h" |
| 10 #include "src/full-codegen/full-codegen.h" | 10 #include "src/full-codegen/full-codegen.h" |
| (...skipping 939 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 950 Label loop_header, loop_check; | 950 Label loop_header, loop_check; |
| 951 __ Branch(&loop_check); | 951 __ Branch(&loop_check); |
| 952 __ bind(&loop_header); | 952 __ bind(&loop_header); |
| 953 __ lw(t1, MemOperand(a2)); | 953 __ lw(t1, MemOperand(a2)); |
| 954 __ Addu(a2, a2, Operand(-kPointerSize)); | 954 __ Addu(a2, a2, Operand(-kPointerSize)); |
| 955 __ push(t1); | 955 __ push(t1); |
| 956 __ bind(&loop_check); | 956 __ bind(&loop_check); |
| 957 __ Branch(&loop_header, gt, a2, Operand(t0)); | 957 __ Branch(&loop_header, gt, a2, Operand(t0)); |
| 958 | 958 |
| 959 // Call the constructor with a0, a1, and a3 unmodified. | 959 // Call the constructor with a0, a1, and a3 unmodified. |
| 960 __ Jump(masm->isolate()->builtins()->Construct(), RelocInfo::CONSTRUCT_CALL); | 960 __ Jump(masm->isolate()->builtins()->Construct(), RelocInfo::CODE_TARGET); |
| 961 } | 961 } |
| 962 | 962 |
| 963 | 963 |
| 964 void Builtins::Generate_CompileLazy(MacroAssembler* masm) { | 964 void Builtins::Generate_CompileLazy(MacroAssembler* masm) { |
| 965 CallRuntimePassFunction(masm, Runtime::kCompileLazy); | 965 CallRuntimePassFunction(masm, Runtime::kCompileLazy); |
| 966 GenerateTailCallToReturnedCode(masm); | 966 GenerateTailCallToReturnedCode(masm); |
| 967 } | 967 } |
| 968 | 968 |
| 969 | 969 |
| 970 void Builtins::Generate_CompileOptimized(MacroAssembler* masm) { | 970 void Builtins::Generate_CompileOptimized(MacroAssembler* masm) { |
| (...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1511 // Copy all arguments from the array to the stack. | 1511 // Copy all arguments from the array to the stack. |
| 1512 Generate_PushAppliedArguments(masm, kVectorOffset, kArgumentsOffset, | 1512 Generate_PushAppliedArguments(masm, kVectorOffset, kArgumentsOffset, |
| 1513 kIndexOffset, kLimitOffset); | 1513 kIndexOffset, kLimitOffset); |
| 1514 | 1514 |
| 1515 // Use undefined feedback vector | 1515 // Use undefined feedback vector |
| 1516 __ LoadRoot(a2, Heap::kUndefinedValueRootIndex); | 1516 __ LoadRoot(a2, Heap::kUndefinedValueRootIndex); |
| 1517 __ lw(a1, MemOperand(fp, kFunctionOffset)); | 1517 __ lw(a1, MemOperand(fp, kFunctionOffset)); |
| 1518 __ lw(a3, MemOperand(fp, kNewTargetOffset)); | 1518 __ lw(a3, MemOperand(fp, kNewTargetOffset)); |
| 1519 | 1519 |
| 1520 // Call the function. | 1520 // Call the function. |
| 1521 __ Call(masm->isolate()->builtins()->Construct(), | 1521 __ Call(masm->isolate()->builtins()->Construct(), RelocInfo::CODE_TARGET); |
| 1522 RelocInfo::CONSTRUCT_CALL); | |
| 1523 | 1522 |
| 1524 // Leave internal frame. | 1523 // Leave internal frame. |
| 1525 } | 1524 } |
| 1526 __ jr(ra); | 1525 __ jr(ra); |
| 1527 __ Addu(sp, sp, Operand(kStackSize * kPointerSize)); // In delay slot. | 1526 __ Addu(sp, sp, Operand(kStackSize * kPointerSize)); // In delay slot. |
| 1528 } | 1527 } |
| 1529 | 1528 |
| 1530 | 1529 |
| 1531 void Builtins::Generate_FunctionApply(MacroAssembler* masm) { | 1530 void Builtins::Generate_FunctionApply(MacroAssembler* masm) { |
| 1532 Generate_ApplyHelper(masm, false); | 1531 Generate_ApplyHelper(masm, false); |
| (...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1986 } | 1985 } |
| 1987 } | 1986 } |
| 1988 | 1987 |
| 1989 | 1988 |
| 1990 #undef __ | 1989 #undef __ |
| 1991 | 1990 |
| 1992 } // namespace internal | 1991 } // namespace internal |
| 1993 } // namespace v8 | 1992 } // namespace v8 |
| 1994 | 1993 |
| 1995 #endif // V8_TARGET_ARCH_MIPS | 1994 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |