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

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

Issue 962263002: Disallow subclassing Arrays. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fixes for debug-code issues Created 5 years, 9 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/arm/full-codegen-arm.cc ('k') | src/arm64/code-stubs-arm64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_ARM64 7 #if V8_TARGET_ARCH_ARM64
8 8
9 #include "src/codegen.h" 9 #include "src/codegen.h"
10 #include "src/debug.h" 10 #include "src/debug.h"
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 // Initial map for the builtin Array functions should be maps. 119 // Initial map for the builtin Array functions should be maps.
120 __ Ldr(x10, FieldMemOperand(x1, JSFunction::kPrototypeOrInitialMapOffset)); 120 __ Ldr(x10, FieldMemOperand(x1, JSFunction::kPrototypeOrInitialMapOffset));
121 __ Tst(x10, kSmiTagMask); 121 __ Tst(x10, kSmiTagMask);
122 __ Assert(ne, kUnexpectedInitialMapForArrayFunction); 122 __ Assert(ne, kUnexpectedInitialMapForArrayFunction);
123 __ CompareObjectType(x10, x11, x12, MAP_TYPE); 123 __ CompareObjectType(x10, x11, x12, MAP_TYPE);
124 __ Assert(eq, kUnexpectedInitialMapForArrayFunction); 124 __ Assert(eq, kUnexpectedInitialMapForArrayFunction);
125 } 125 }
126 126
127 // Run the native code for the Array function called as a normal function. 127 // Run the native code for the Array function called as a normal function.
128 __ LoadRoot(x2, Heap::kUndefinedValueRootIndex); 128 __ LoadRoot(x2, Heap::kUndefinedValueRootIndex);
129 __ Mov(x3, x1);
129 ArrayConstructorStub stub(masm->isolate()); 130 ArrayConstructorStub stub(masm->isolate());
130 __ TailCallStub(&stub); 131 __ TailCallStub(&stub);
131 } 132 }
132 133
133 134
134 void Builtins::Generate_StringConstructCode(MacroAssembler* masm) { 135 void Builtins::Generate_StringConstructCode(MacroAssembler* masm) {
135 // ----------- S t a t e ------------- 136 // ----------- S t a t e -------------
136 // -- x0 : number of arguments 137 // -- x0 : number of arguments
137 // -- x1 : constructor function 138 // -- x1 : constructor function
138 // -- lr : return address 139 // -- lr : return address
(...skipping 1529 matching lines...) Expand 10 before | Expand all | Expand 10 after
1668 __ Unreachable(); 1669 __ Unreachable();
1669 } 1670 }
1670 } 1671 }
1671 1672
1672 1673
1673 #undef __ 1674 #undef __
1674 1675
1675 } } // namespace v8::internal 1676 } } // namespace v8::internal
1676 1677
1677 #endif // V8_TARGET_ARCH_ARM 1678 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/full-codegen-arm.cc ('k') | src/arm64/code-stubs-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698