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/base/bits.h" | 5 #include "src/base/bits.h" |
6 #include "src/compiler/instruction-selector-impl.h" | 6 #include "src/compiler/instruction-selector-impl.h" |
7 #include "src/compiler/node-matchers.h" | 7 #include "src/compiler/node-matchers.h" |
8 #include "src/compiler/node-properties.h" | 8 #include "src/compiler/node-properties.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
11 namespace internal { | 11 namespace internal { |
12 namespace compiler { | 12 namespace compiler { |
13 | 13 |
14 #define TRACE_UNIMPL() \ | 14 #define TRACE_UNIMPL() \ |
15 PrintF("UNIMPLEMENTED instr_sel: %s at line %d\n", __FUNCTION__, __LINE__) | 15 PrintF("UNIMPLEMENTED instr_sel: %s at line %d\n", __FUNCTION__, __LINE__) |
16 | 16 |
17 #define TRACE() PrintF("instr_sel: %s at line %d\n", __FUNCTION__, __LINE__) | 17 #define TRACE() PrintF("instr_sel: %s at line %d\n", __FUNCTION__, __LINE__) |
18 | 18 |
19 | 19 |
20 // Adds Mips-specific methods for generating InstructionOperands. | 20 // Adds Mips-specific methods for generating InstructionOperands. |
21 class Mips64OperandGenerator FINAL : public OperandGenerator { | 21 class Mips64OperandGenerator final : public OperandGenerator { |
22 public: | 22 public: |
23 explicit Mips64OperandGenerator(InstructionSelector* selector) | 23 explicit Mips64OperandGenerator(InstructionSelector* selector) |
24 : OperandGenerator(selector) {} | 24 : OperandGenerator(selector) {} |
25 | 25 |
26 InstructionOperand UseOperand(Node* node, InstructionCode opcode) { | 26 InstructionOperand UseOperand(Node* node, InstructionCode opcode) { |
27 if (CanBeImmediate(node, opcode)) { | 27 if (CanBeImmediate(node, opcode)) { |
28 return UseImmediate(node); | 28 return UseImmediate(node); |
29 } | 29 } |
30 return UseRegister(node); | 30 return UseRegister(node); |
31 } | 31 } |
(...skipping 1156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1188 InstructionSelector::SupportedMachineOperatorFlags() { | 1188 InstructionSelector::SupportedMachineOperatorFlags() { |
1189 return MachineOperatorBuilder::kFloat32Abs | | 1189 return MachineOperatorBuilder::kFloat32Abs | |
1190 MachineOperatorBuilder::kFloat64Abs | | 1190 MachineOperatorBuilder::kFloat64Abs | |
1191 MachineOperatorBuilder::kFloat64RoundDown | | 1191 MachineOperatorBuilder::kFloat64RoundDown | |
1192 MachineOperatorBuilder::kFloat64RoundTruncate; | 1192 MachineOperatorBuilder::kFloat64RoundTruncate; |
1193 } | 1193 } |
1194 | 1194 |
1195 } // namespace compiler | 1195 } // namespace compiler |
1196 } // namespace internal | 1196 } // namespace internal |
1197 } // namespace v8 | 1197 } // namespace v8 |
OLD | NEW |