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

Side by Side Diff: src/compiler/raw-machine-assembler.cc

Issue 2833463002: [arm64] Support passing more than eight arguments to C functions (Closed)
Patch Set: [arm64] Support passing more than eight arguments to C functions Created 3 years, 8 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/compiler/raw-machine-assembler.h ('k') | test/cctest/compiler/test-run-machops.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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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/compiler/raw-machine-assembler.h" 5 #include "src/compiler/raw-machine-assembler.h"
6 6
7 #include "src/compiler/node-properties.h" 7 #include "src/compiler/node-properties.h"
8 #include "src/compiler/pipeline.h" 8 #include "src/compiler/pipeline.h"
9 #include "src/compiler/scheduler.h" 9 #include "src/compiler/scheduler.h"
10 #include "src/objects-inl.h" 10 #include "src/objects-inl.h"
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
291 builder.AddParam(arg3_type); 291 builder.AddParam(arg3_type);
292 builder.AddParam(arg4_type); 292 builder.AddParam(arg4_type);
293 builder.AddParam(arg5_type); 293 builder.AddParam(arg5_type);
294 builder.AddParam(arg6_type); 294 builder.AddParam(arg6_type);
295 builder.AddParam(arg7_type); 295 builder.AddParam(arg7_type);
296 Node* args[] = {function, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7}; 296 Node* args[] = {function, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7};
297 const CallDescriptor* descriptor = 297 const CallDescriptor* descriptor =
298 Linkage::GetSimplifiedCDescriptor(zone(), builder.Build()); 298 Linkage::GetSimplifiedCDescriptor(zone(), builder.Build());
299 return AddNode(common()->Call(descriptor), arraysize(args), args); 299 return AddNode(common()->Call(descriptor), arraysize(args), args);
300 } 300 }
301
302 Node* RawMachineAssembler::CallCFunction9(
303 MachineType return_type, MachineType arg0_type, MachineType arg1_type,
304 MachineType arg2_type, MachineType arg3_type, MachineType arg4_type,
305 MachineType arg5_type, MachineType arg6_type, MachineType arg7_type,
306 MachineType arg8_type, Node* function, Node* arg0, Node* arg1, Node* arg2,
307 Node* arg3, Node* arg4, Node* arg5, Node* arg6, Node* arg7, Node* arg8) {
308 MachineSignature::Builder builder(zone(), 1, 9);
309 builder.AddReturn(return_type);
310 builder.AddParam(arg0_type);
311 builder.AddParam(arg1_type);
312 builder.AddParam(arg2_type);
313 builder.AddParam(arg3_type);
314 builder.AddParam(arg4_type);
315 builder.AddParam(arg5_type);
316 builder.AddParam(arg6_type);
317 builder.AddParam(arg7_type);
318 builder.AddParam(arg8_type);
319 Node* args[] = {function, arg0, arg1, arg2, arg3,
320 arg4, arg5, arg6, arg7, arg8};
321 const CallDescriptor* descriptor =
322 Linkage::GetSimplifiedCDescriptor(zone(), builder.Build());
323 return AddNode(common()->Call(descriptor), arraysize(args), args);
324 }
325
301 BasicBlock* RawMachineAssembler::Use(RawMachineLabel* label) { 326 BasicBlock* RawMachineAssembler::Use(RawMachineLabel* label) {
302 label->used_ = true; 327 label->used_ = true;
303 return EnsureBlock(label); 328 return EnsureBlock(label);
304 } 329 }
305 330
306 BasicBlock* RawMachineAssembler::EnsureBlock(RawMachineLabel* label) { 331 BasicBlock* RawMachineAssembler::EnsureBlock(RawMachineLabel* label) {
307 if (label->block_ == nullptr) { 332 if (label->block_ == nullptr) {
308 label->block_ = schedule()->NewBasicBlock(); 333 label->block_ = schedule()->NewBasicBlock();
309 } 334 }
310 return label->block_; 335 return label->block_;
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
381 406
382 RawMachineLabel::~RawMachineLabel() { 407 RawMachineLabel::~RawMachineLabel() {
383 // If this DCHECK fails, it means that the label has been bound but it's not 408 // If this DCHECK fails, it means that the label has been bound but it's not
384 // used, or the opposite. This would cause the register allocator to crash. 409 // used, or the opposite. This would cause the register allocator to crash.
385 DCHECK_EQ(bound_, used_); 410 DCHECK_EQ(bound_, used_);
386 } 411 }
387 412
388 } // namespace compiler 413 } // namespace compiler
389 } // namespace internal 414 } // namespace internal
390 } // namespace v8 415 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/raw-machine-assembler.h ('k') | test/cctest/compiler/test-run-machops.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698