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_MIPS64 | 5 #if V8_TARGET_ARCH_MIPS64 |
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 1718 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1729 ExternalReference::get_date_field_function(masm->isolate()), 2); | 1729 ExternalReference::get_date_field_function(masm->isolate()), 2); |
1730 } | 1730 } |
1731 __ Ret(); | 1731 __ Ret(); |
1732 | 1732 |
1733 // 3. Raise a TypeError if the receiver is not a date. | 1733 // 3. Raise a TypeError if the receiver is not a date. |
1734 __ bind(&receiver_not_date); | 1734 __ bind(&receiver_not_date); |
1735 __ TailCallRuntime(Runtime::kThrowNotDateError); | 1735 __ TailCallRuntime(Runtime::kThrowNotDateError); |
1736 } | 1736 } |
1737 | 1737 |
1738 // static | 1738 // static |
1739 void Builtins::Generate_FunctionHasInstance(MacroAssembler* masm) { | |
1740 // ----------- S t a t e ------------- | |
1741 // -- a0 : argc | |
1742 // -- sp[0] : first argument (left-hand side) | |
1743 // -- sp[8] : receiver (right-hand side) | |
1744 // ----------------------------------- | |
1745 | |
1746 { | |
1747 FrameScope scope(masm, StackFrame::INTERNAL); | |
1748 __ ld(InstanceOfDescriptor::LeftRegister(), | |
1749 MemOperand(fp, 2 * kPointerSize)); // Load left-hand side. | |
1750 __ ld(InstanceOfDescriptor::RightRegister(), | |
1751 MemOperand(fp, 3 * kPointerSize)); // Load right-hand side. | |
1752 InstanceOfStub stub(masm->isolate(), true); | |
1753 __ CallStub(&stub); | |
1754 } | |
1755 | |
1756 // Pop the argument and the receiver. | |
1757 __ DropAndRet(2); | |
1758 } | |
1759 | |
1760 // static | |
1761 void Builtins::Generate_FunctionPrototypeApply(MacroAssembler* masm) { | 1739 void Builtins::Generate_FunctionPrototypeApply(MacroAssembler* masm) { |
1762 // ----------- S t a t e ------------- | 1740 // ----------- S t a t e ------------- |
1763 // -- a0 : argc | 1741 // -- a0 : argc |
1764 // -- sp[0] : argArray | 1742 // -- sp[0] : argArray |
1765 // -- sp[4] : thisArg | 1743 // -- sp[4] : thisArg |
1766 // -- sp[8] : receiver | 1744 // -- sp[8] : receiver |
1767 // ----------------------------------- | 1745 // ----------------------------------- |
1768 | 1746 |
1769 // 1. Load receiver into a1, argArray into a0 (if present), remove all | 1747 // 1. Load receiver into a1, argArray into a0 (if present), remove all |
1770 // arguments from the stack (including the receiver), and push thisArg (if | 1748 // arguments from the stack (including the receiver), and push thisArg (if |
(...skipping 1113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2884 } | 2862 } |
2885 } | 2863 } |
2886 | 2864 |
2887 | 2865 |
2888 #undef __ | 2866 #undef __ |
2889 | 2867 |
2890 } // namespace internal | 2868 } // namespace internal |
2891 } // namespace v8 | 2869 } // namespace v8 |
2892 | 2870 |
2893 #endif // V8_TARGET_ARCH_MIPS64 | 2871 #endif // V8_TARGET_ARCH_MIPS64 |
OLD | NEW |