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/instruction-selector-impl.h" | 5 #include "src/compiler/instruction-selector-impl.h" |
6 #include "src/compiler/node-matchers.h" | 6 #include "src/compiler/node-matchers.h" |
7 #include "src/compiler/node-properties.h" | 7 #include "src/compiler/node-properties.h" |
8 | 8 |
9 namespace v8 { | 9 namespace v8 { |
10 namespace internal { | 10 namespace internal { |
(...skipping 1246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1257 | 1257 |
1258 Emit(kArm64Float64ToInt64, output_count, outputs, 1, inputs); | 1258 Emit(kArm64Float64ToInt64, output_count, outputs, 1, inputs); |
1259 } | 1259 } |
1260 | 1260 |
1261 | 1261 |
1262 void InstructionSelector::VisitTruncateFloat32ToUint64(Node* node) { | 1262 void InstructionSelector::VisitTruncateFloat32ToUint64(Node* node) { |
1263 VisitRR(this, kArm64Float32ToUint64, node); | 1263 VisitRR(this, kArm64Float32ToUint64, node); |
1264 } | 1264 } |
1265 | 1265 |
1266 | 1266 |
1267 void InstructionSelector::VisitTruncateFloat64ToUint64(Node* node) { | 1267 void InstructionSelector::VisitTryTruncateFloat64ToUint64(Node* node) { |
1268 VisitRR(this, kArm64Float64ToUint64, node); | 1268 Arm64OperandGenerator g(this); |
| 1269 |
| 1270 InstructionOperand inputs[] = {g.UseRegister(node->InputAt(0))}; |
| 1271 InstructionOperand outputs[2]; |
| 1272 size_t output_count = 0; |
| 1273 outputs[output_count++] = g.DefineAsRegister(node); |
| 1274 |
| 1275 Node* success_output = NodeProperties::FindProjection(node, 1); |
| 1276 if (success_output) { |
| 1277 outputs[output_count++] = g.DefineAsRegister(success_output); |
| 1278 } |
| 1279 |
| 1280 Emit(kArm64Float64ToUint64, output_count, outputs, 1, inputs); |
1269 } | 1281 } |
1270 | 1282 |
1271 | 1283 |
1272 void InstructionSelector::VisitChangeInt32ToInt64(Node* node) { | 1284 void InstructionSelector::VisitChangeInt32ToInt64(Node* node) { |
1273 VisitRR(this, kArm64Sxtw, node); | 1285 VisitRR(this, kArm64Sxtw, node); |
1274 } | 1286 } |
1275 | 1287 |
1276 | 1288 |
1277 void InstructionSelector::VisitChangeUint32ToUint64(Node* node) { | 1289 void InstructionSelector::VisitChangeUint32ToUint64(Node* node) { |
1278 Arm64OperandGenerator g(this); | 1290 Arm64OperandGenerator g(this); |
(...skipping 843 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2122 MachineOperatorBuilder::kFloat32RoundTiesEven | | 2134 MachineOperatorBuilder::kFloat32RoundTiesEven | |
2123 MachineOperatorBuilder::kFloat64RoundTiesEven | | 2135 MachineOperatorBuilder::kFloat64RoundTiesEven | |
2124 MachineOperatorBuilder::kWord32ShiftIsSafe | | 2136 MachineOperatorBuilder::kWord32ShiftIsSafe | |
2125 MachineOperatorBuilder::kInt32DivIsSafe | | 2137 MachineOperatorBuilder::kInt32DivIsSafe | |
2126 MachineOperatorBuilder::kUint32DivIsSafe; | 2138 MachineOperatorBuilder::kUint32DivIsSafe; |
2127 } | 2139 } |
2128 | 2140 |
2129 } // namespace compiler | 2141 } // namespace compiler |
2130 } // namespace internal | 2142 } // namespace internal |
2131 } // namespace v8 | 2143 } // namespace v8 |
OLD | NEW |