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

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

Issue 1556913002: Use register arguments for RestParamAccessStub (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Ports. Created 4 years, 11 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/full-codegen/arm/full-codegen-arm.cc ('k') | src/full-codegen/ia32/full-codegen-ia32.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 #if V8_TARGET_ARCH_ARM64 5 #if V8_TARGET_ARCH_ARM64
6 6
7 #include "src/ast/scopes.h" 7 #include "src/ast/scopes.h"
8 #include "src/code-factory.h" 8 #include "src/code-factory.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 } 263 }
264 264
265 // Possibly allocate RestParameters 265 // Possibly allocate RestParameters
266 int rest_index; 266 int rest_index;
267 Variable* rest_param = scope()->rest_parameter(&rest_index); 267 Variable* rest_param = scope()->rest_parameter(&rest_index);
268 if (rest_param) { 268 if (rest_param) {
269 Comment cmnt(masm_, "[ Allocate rest parameter array"); 269 Comment cmnt(masm_, "[ Allocate rest parameter array");
270 270
271 int num_parameters = info->scope()->num_parameters(); 271 int num_parameters = info->scope()->num_parameters();
272 int offset = num_parameters * kPointerSize; 272 int offset = num_parameters * kPointerSize;
273 __ Mov(RestParamAccessDescriptor::parameter_count(),
274 Smi::FromInt(num_parameters));
275 __ Add(RestParamAccessDescriptor::parameter_pointer(), fp,
276 StandardFrameConstants::kCallerSPOffset + offset);
277 __ Mov(RestParamAccessDescriptor::rest_parameter_index(),
278 Smi::FromInt(rest_index));
279 __ Mov(RestParamAccessDescriptor::language_mode(),
280 Smi::FromInt(language_mode()));
281 DCHECK(x1.is(RestParamAccessDescriptor::language_mode()));
273 282
274 __ Add(x3, fp, StandardFrameConstants::kCallerSPOffset + offset);
275 __ Mov(x2, Smi::FromInt(num_parameters));
276 __ Mov(x1, Smi::FromInt(rest_index));
277 __ Mov(x0, Smi::FromInt(language_mode()));
278 __ Push(x3, x2, x1, x0);
279 function_in_register_x1 = false; 283 function_in_register_x1 = false;
280 284
281 RestParamAccessStub stub(isolate()); 285 RestParamAccessStub stub(isolate());
282 __ CallStub(&stub); 286 __ CallStub(&stub);
283 287
284 SetVar(rest_param, x0, x1, x2); 288 SetVar(rest_param, x0, x1, x2);
285 } 289 }
286 290
287 Variable* arguments = scope()->arguments(); 291 Variable* arguments = scope()->arguments();
288 if (arguments != NULL) { 292 if (arguments != NULL) {
(...skipping 4603 matching lines...) Expand 10 before | Expand all | Expand 10 after
4892 } 4896 }
4893 4897
4894 return INTERRUPT; 4898 return INTERRUPT;
4895 } 4899 }
4896 4900
4897 4901
4898 } // namespace internal 4902 } // namespace internal
4899 } // namespace v8 4903 } // namespace v8
4900 4904
4901 #endif // V8_TARGET_ARCH_ARM64 4905 #endif // V8_TARGET_ARCH_ARM64
OLDNEW
« no previous file with comments | « src/full-codegen/arm/full-codegen-arm.cc ('k') | src/full-codegen/ia32/full-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698