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

Side by Side Diff: src/compiler/arm64/instruction-selector-arm64.cc

Issue 1504363002: [turbofan] Change TruncateFloat32ToInt64 to TryTruncateFloat32ToInt64. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Removed bad code in the mips code Created 5 years 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/arm64/code-generator-arm64.cc ('k') | src/compiler/instruction-selector.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/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 1219 matching lines...) Expand 10 before | Expand all | Expand 10 after
1230 void InstructionSelector::VisitChangeFloat64ToInt32(Node* node) { 1230 void InstructionSelector::VisitChangeFloat64ToInt32(Node* node) {
1231 VisitRR(this, kArm64Float64ToInt32, node); 1231 VisitRR(this, kArm64Float64ToInt32, node);
1232 } 1232 }
1233 1233
1234 1234
1235 void InstructionSelector::VisitChangeFloat64ToUint32(Node* node) { 1235 void InstructionSelector::VisitChangeFloat64ToUint32(Node* node) {
1236 VisitRR(this, kArm64Float64ToUint32, node); 1236 VisitRR(this, kArm64Float64ToUint32, node);
1237 } 1237 }
1238 1238
1239 1239
1240 void InstructionSelector::VisitTruncateFloat32ToInt64(Node* node) { 1240 void InstructionSelector::VisitTryTruncateFloat32ToInt64(Node* node) {
1241 VisitRR(this, kArm64Float32ToInt64, node); 1241 Arm64OperandGenerator g(this);
1242
1243 InstructionOperand inputs[] = {g.UseRegister(node->InputAt(0))};
1244 InstructionOperand outputs[2];
1245 size_t output_count = 0;
1246 outputs[output_count++] = g.DefineAsRegister(node);
1247
1248 Node* success_output = NodeProperties::FindProjection(node, 1);
1249 if (success_output) {
1250 outputs[output_count++] = g.DefineAsRegister(success_output);
1251 }
1252
1253 Emit(kArm64Float32ToInt64, output_count, outputs, 1, inputs);
1242 } 1254 }
1243 1255
1244 1256
1245 void InstructionSelector::VisitTryTruncateFloat64ToInt64(Node* node) { 1257 void InstructionSelector::VisitTryTruncateFloat64ToInt64(Node* node) {
1246 Arm64OperandGenerator g(this); 1258 Arm64OperandGenerator g(this);
1247 1259
1248 InstructionOperand inputs[] = {g.UseRegister(node->InputAt(0))}; 1260 InstructionOperand inputs[] = {g.UseRegister(node->InputAt(0))};
1249 InstructionOperand outputs[2]; 1261 InstructionOperand outputs[2];
1250 size_t output_count = 0; 1262 size_t output_count = 0;
1251 outputs[output_count++] = g.DefineAsRegister(node); 1263 outputs[output_count++] = g.DefineAsRegister(node);
(...skipping 882 matching lines...) Expand 10 before | Expand all | Expand 10 after
2134 MachineOperatorBuilder::kFloat32RoundTiesEven | 2146 MachineOperatorBuilder::kFloat32RoundTiesEven |
2135 MachineOperatorBuilder::kFloat64RoundTiesEven | 2147 MachineOperatorBuilder::kFloat64RoundTiesEven |
2136 MachineOperatorBuilder::kWord32ShiftIsSafe | 2148 MachineOperatorBuilder::kWord32ShiftIsSafe |
2137 MachineOperatorBuilder::kInt32DivIsSafe | 2149 MachineOperatorBuilder::kInt32DivIsSafe |
2138 MachineOperatorBuilder::kUint32DivIsSafe; 2150 MachineOperatorBuilder::kUint32DivIsSafe;
2139 } 2151 }
2140 2152
2141 } // namespace compiler 2153 } // namespace compiler
2142 } // namespace internal 2154 } // namespace internal
2143 } // namespace v8 2155 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/arm64/code-generator-arm64.cc ('k') | src/compiler/instruction-selector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698