Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(232)

Side by Side Diff: src/mips64/builtins-mips64.cc

Issue 1980483003: [es6] Reintroduce the instanceof operator in the backends. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Igors comments. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/mips/interface-descriptors-mips.cc ('k') | src/mips64/code-stubs-mips64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
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
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
OLDNEW
« no previous file with comments | « src/mips/interface-descriptors-mips.cc ('k') | src/mips64/code-stubs-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698