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

Side by Side Diff: src/full-codegen/arm/full-codegen-arm.cc

Issue 2645743002: [builtins] Port parameter and argument-related code stubs to CSA (Closed)
Patch Set: Review feedback Created 3 years, 10 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/code-stubs.h ('k') | src/full-codegen/arm64/full-codegen-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 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_ARM 5 #if V8_TARGET_ARCH_ARM
6 6
7 #include "src/ast/compile-time-value.h" 7 #include "src/ast/compile-time-value.h"
8 #include "src/ast/scopes.h" 8 #include "src/ast/scopes.h"
9 #include "src/builtins/builtins-constructor.h" 9 #include "src/builtins/builtins-constructor.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
264 264
265 Variable* arguments = info->scope()->arguments(); 265 Variable* arguments = info->scope()->arguments();
266 if (arguments != NULL) { 266 if (arguments != NULL) {
267 // Function uses arguments object. 267 // Function uses arguments object.
268 Comment cmnt(masm_, "[ Allocate arguments object"); 268 Comment cmnt(masm_, "[ Allocate arguments object");
269 if (!function_in_register_r1) { 269 if (!function_in_register_r1) {
270 // Load this again, if it's used by the local context below. 270 // Load this again, if it's used by the local context below.
271 __ ldr(r1, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset)); 271 __ ldr(r1, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset));
272 } 272 }
273 if (is_strict(language_mode()) || !has_simple_parameters()) { 273 if (is_strict(language_mode()) || !has_simple_parameters()) {
274 FastNewStrictArgumentsStub stub(isolate()); 274 Callable callable = CodeFactory::FastNewStrictArguments(isolate());
275 __ CallStub(&stub); 275 __ Call(callable.code(), RelocInfo::CODE_TARGET);
276 RestoreContext();
276 } else if (literal()->has_duplicate_parameters()) { 277 } else if (literal()->has_duplicate_parameters()) {
277 __ Push(r1); 278 __ Push(r1);
278 __ CallRuntime(Runtime::kNewSloppyArguments_Generic); 279 __ CallRuntime(Runtime::kNewSloppyArguments_Generic);
279 } else { 280 } else {
280 FastNewSloppyArgumentsStub stub(isolate()); 281 Callable callable = CodeFactory::FastNewSloppyArguments(isolate());
281 __ CallStub(&stub); 282 __ Call(callable.code(), RelocInfo::CODE_TARGET);
283 RestoreContext();
282 } 284 }
283 285
284 SetVar(arguments, r0, r1, r2); 286 SetVar(arguments, r0, r1, r2);
285 } 287 }
286 288
287 if (FLAG_trace) { 289 if (FLAG_trace) {
288 __ CallRuntime(Runtime::kTraceEnter); 290 __ CallRuntime(Runtime::kTraceEnter);
289 } 291 }
290 292
291 // Visit the declarations and body. 293 // Visit the declarations and body.
(...skipping 2618 matching lines...) Expand 10 before | Expand all | Expand 10 after
2910 DCHECK(interrupt_address == 2912 DCHECK(interrupt_address ==
2911 isolate->builtins()->OnStackReplacement()->entry()); 2913 isolate->builtins()->OnStackReplacement()->entry());
2912 return ON_STACK_REPLACEMENT; 2914 return ON_STACK_REPLACEMENT;
2913 } 2915 }
2914 2916
2915 2917
2916 } // namespace internal 2918 } // namespace internal
2917 } // namespace v8 2919 } // namespace v8
2918 2920
2919 #endif // V8_TARGET_ARCH_ARM 2921 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/code-stubs.h ('k') | src/full-codegen/arm64/full-codegen-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698