OLD | NEW |
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/code-factory.h" | 7 #include "src/code-factory.h" |
8 #include "src/compiler/node-properties.h" | 8 #include "src/compiler/node-properties.h" |
9 #include "src/compiler/pipeline.h" | 9 #include "src/compiler/pipeline.h" |
10 #include "src/compiler/scheduler.h" | 10 #include "src/compiler/scheduler.h" |
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
403 MachineSignature::Builder builder(zone(), 1, 2); | 403 MachineSignature::Builder builder(zone(), 1, 2); |
404 builder.AddReturn(return_type); | 404 builder.AddReturn(return_type); |
405 builder.AddParam(arg0_type); | 405 builder.AddParam(arg0_type); |
406 builder.AddParam(arg1_type); | 406 builder.AddParam(arg1_type); |
407 const CallDescriptor* descriptor = | 407 const CallDescriptor* descriptor = |
408 Linkage::GetSimplifiedCDescriptor(zone(), builder.Build()); | 408 Linkage::GetSimplifiedCDescriptor(zone(), builder.Build()); |
409 | 409 |
410 return AddNode(common()->Call(descriptor), function, arg0, arg1); | 410 return AddNode(common()->Call(descriptor), function, arg0, arg1); |
411 } | 411 } |
412 | 412 |
| 413 Node* RawMachineAssembler::CallCFunction3(MachineType return_type, |
| 414 MachineType arg0_type, |
| 415 MachineType arg1_type, |
| 416 MachineType arg2_type, Node* function, |
| 417 Node* arg0, Node* arg1, Node* arg2) { |
| 418 MachineSignature::Builder builder(zone(), 1, 3); |
| 419 builder.AddReturn(return_type); |
| 420 builder.AddParam(arg0_type); |
| 421 builder.AddParam(arg1_type); |
| 422 builder.AddParam(arg2_type); |
| 423 const CallDescriptor* descriptor = |
| 424 Linkage::GetSimplifiedCDescriptor(zone(), builder.Build()); |
| 425 |
| 426 return AddNode(common()->Call(descriptor), function, arg0, arg1, arg2); |
| 427 } |
413 | 428 |
414 Node* RawMachineAssembler::CallCFunction8( | 429 Node* RawMachineAssembler::CallCFunction8( |
415 MachineType return_type, MachineType arg0_type, MachineType arg1_type, | 430 MachineType return_type, MachineType arg0_type, MachineType arg1_type, |
416 MachineType arg2_type, MachineType arg3_type, MachineType arg4_type, | 431 MachineType arg2_type, MachineType arg3_type, MachineType arg4_type, |
417 MachineType arg5_type, MachineType arg6_type, MachineType arg7_type, | 432 MachineType arg5_type, MachineType arg6_type, MachineType arg7_type, |
418 Node* function, Node* arg0, Node* arg1, Node* arg2, Node* arg3, Node* arg4, | 433 Node* function, Node* arg0, Node* arg1, Node* arg2, Node* arg3, Node* arg4, |
419 Node* arg5, Node* arg6, Node* arg7) { | 434 Node* arg5, Node* arg6, Node* arg7) { |
420 MachineSignature::Builder builder(zone(), 1, 8); | 435 MachineSignature::Builder builder(zone(), 1, 8); |
421 builder.AddReturn(return_type); | 436 builder.AddReturn(return_type); |
422 builder.AddParam(arg0_type); | 437 builder.AddParam(arg0_type); |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
490 // The raw machine assembler nodes do not have effect and control inputs, | 505 // The raw machine assembler nodes do not have effect and control inputs, |
491 // so we disable checking input counts here. | 506 // so we disable checking input counts here. |
492 return graph()->NewNodeUnchecked(op, input_count, inputs); | 507 return graph()->NewNodeUnchecked(op, input_count, inputs); |
493 } | 508 } |
494 | 509 |
495 RawMachineLabel::~RawMachineLabel() { DCHECK(bound_ || !used_); } | 510 RawMachineLabel::~RawMachineLabel() { DCHECK(bound_ || !used_); } |
496 | 511 |
497 } // namespace compiler | 512 } // namespace compiler |
498 } // namespace internal | 513 } // namespace internal |
499 } // namespace v8 | 514 } // namespace v8 |
OLD | NEW |