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

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

Issue 1477753002: [turbofan] Implemented the optional Float32RoundTiesEven operator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@f32trunc
Patch Set: Merging with the changed codebase 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/instruction-selector-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/base/adapters.h" 5 #include "src/base/adapters.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 {
(...skipping 868 matching lines...) Expand 10 before | Expand all | Expand 10 after
879 void InstructionSelector::VisitFloat64RoundTruncate(Node* node) { 879 void InstructionSelector::VisitFloat64RoundTruncate(Node* node) {
880 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToZero)); 880 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToZero));
881 } 881 }
882 882
883 883
884 void InstructionSelector::VisitFloat64RoundTiesAway(Node* node) { 884 void InstructionSelector::VisitFloat64RoundTiesAway(Node* node) {
885 UNREACHABLE(); 885 UNREACHABLE();
886 } 886 }
887 887
888 888
889 void InstructionSelector::VisitFloat32RoundTiesEven(Node* node) {
890 VisitRR(this, node, kSSEFloat32Round | MiscField::encode(kRoundToNearest));
891 }
892
893
889 void InstructionSelector::VisitFloat64RoundTiesEven(Node* node) { 894 void InstructionSelector::VisitFloat64RoundTiesEven(Node* node) {
890 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToNearest)); 895 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToNearest));
891 } 896 }
892 897
893 898
894 void InstructionSelector::EmitPrepareArguments(NodeVector* arguments, 899 void InstructionSelector::EmitPrepareArguments(NodeVector* arguments,
895 const CallDescriptor* descriptor, 900 const CallDescriptor* descriptor,
896 Node* node) { 901 Node* node) {
897 IA32OperandGenerator g(this); 902 IA32OperandGenerator g(this);
898 903
(...skipping 399 matching lines...) Expand 10 before | Expand all | Expand 10 after
1298 if (CpuFeatures::IsSupported(POPCNT)) { 1303 if (CpuFeatures::IsSupported(POPCNT)) {
1299 flags |= MachineOperatorBuilder::kWord32Popcnt; 1304 flags |= MachineOperatorBuilder::kWord32Popcnt;
1300 } 1305 }
1301 if (CpuFeatures::IsSupported(SSE4_1)) { 1306 if (CpuFeatures::IsSupported(SSE4_1)) {
1302 flags |= MachineOperatorBuilder::kFloat32RoundDown | 1307 flags |= MachineOperatorBuilder::kFloat32RoundDown |
1303 MachineOperatorBuilder::kFloat64RoundDown | 1308 MachineOperatorBuilder::kFloat64RoundDown |
1304 MachineOperatorBuilder::kFloat32RoundUp | 1309 MachineOperatorBuilder::kFloat32RoundUp |
1305 MachineOperatorBuilder::kFloat64RoundUp | 1310 MachineOperatorBuilder::kFloat64RoundUp |
1306 MachineOperatorBuilder::kFloat32RoundTruncate | 1311 MachineOperatorBuilder::kFloat32RoundTruncate |
1307 MachineOperatorBuilder::kFloat64RoundTruncate | 1312 MachineOperatorBuilder::kFloat64RoundTruncate |
1313 MachineOperatorBuilder::kFloat32RoundTiesEven |
1308 MachineOperatorBuilder::kFloat64RoundTiesEven; 1314 MachineOperatorBuilder::kFloat64RoundTiesEven;
1309 } 1315 }
1310 return flags; 1316 return flags;
1311 } 1317 }
1312 1318
1313 } // namespace compiler 1319 } // namespace compiler
1314 } // namespace internal 1320 } // namespace internal
1315 } // namespace v8 1321 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/arm64/instruction-selector-arm64.cc ('k') | src/compiler/instruction-selector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698