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 <algorithm> | 5 #include <algorithm> |
6 | 6 |
7 #include "src/base/adapters.h" | 7 #include "src/base/adapters.h" |
8 #include "src/compiler/instruction-selector-impl.h" | 8 #include "src/compiler/instruction-selector-impl.h" |
9 #include "src/compiler/node-matchers.h" | 9 #include "src/compiler/node-matchers.h" |
10 #include "src/compiler/node-properties.h" | 10 #include "src/compiler/node-properties.h" |
(...skipping 1155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1166 void InstructionSelector::VisitFloat64RoundTruncate(Node* node) { | 1166 void InstructionSelector::VisitFloat64RoundTruncate(Node* node) { |
1167 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToZero)); | 1167 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToZero)); |
1168 } | 1168 } |
1169 | 1169 |
1170 | 1170 |
1171 void InstructionSelector::VisitFloat64RoundTiesAway(Node* node) { | 1171 void InstructionSelector::VisitFloat64RoundTiesAway(Node* node) { |
1172 UNREACHABLE(); | 1172 UNREACHABLE(); |
1173 } | 1173 } |
1174 | 1174 |
1175 | 1175 |
| 1176 void InstructionSelector::VisitFloat32RoundTiesEven(Node* node) { |
| 1177 VisitRR(this, node, kSSEFloat32Round | MiscField::encode(kRoundToNearest)); |
| 1178 } |
| 1179 |
| 1180 |
1176 void InstructionSelector::VisitFloat64RoundTiesEven(Node* node) { | 1181 void InstructionSelector::VisitFloat64RoundTiesEven(Node* node) { |
1177 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToNearest)); | 1182 VisitRR(this, node, kSSEFloat64Round | MiscField::encode(kRoundToNearest)); |
1178 } | 1183 } |
1179 | 1184 |
1180 | 1185 |
1181 void InstructionSelector::EmitPrepareArguments(NodeVector* arguments, | 1186 void InstructionSelector::EmitPrepareArguments(NodeVector* arguments, |
1182 const CallDescriptor* descriptor, | 1187 const CallDescriptor* descriptor, |
1183 Node* node) { | 1188 Node* node) { |
1184 X64OperandGenerator g(this); | 1189 X64OperandGenerator g(this); |
1185 | 1190 |
(...skipping 519 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1705 flags |= MachineOperatorBuilder::kWord32Popcnt | | 1710 flags |= MachineOperatorBuilder::kWord32Popcnt | |
1706 MachineOperatorBuilder::kWord64Popcnt; | 1711 MachineOperatorBuilder::kWord64Popcnt; |
1707 } | 1712 } |
1708 if (CpuFeatures::IsSupported(SSE4_1)) { | 1713 if (CpuFeatures::IsSupported(SSE4_1)) { |
1709 flags |= MachineOperatorBuilder::kFloat32RoundDown | | 1714 flags |= MachineOperatorBuilder::kFloat32RoundDown | |
1710 MachineOperatorBuilder::kFloat64RoundDown | | 1715 MachineOperatorBuilder::kFloat64RoundDown | |
1711 MachineOperatorBuilder::kFloat32RoundUp | | 1716 MachineOperatorBuilder::kFloat32RoundUp | |
1712 MachineOperatorBuilder::kFloat64RoundUp | | 1717 MachineOperatorBuilder::kFloat64RoundUp | |
1713 MachineOperatorBuilder::kFloat32RoundTruncate | | 1718 MachineOperatorBuilder::kFloat32RoundTruncate | |
1714 MachineOperatorBuilder::kFloat64RoundTruncate | | 1719 MachineOperatorBuilder::kFloat64RoundTruncate | |
| 1720 MachineOperatorBuilder::kFloat32RoundTiesEven | |
1715 MachineOperatorBuilder::kFloat64RoundTiesEven; | 1721 MachineOperatorBuilder::kFloat64RoundTiesEven; |
1716 } | 1722 } |
1717 return flags; | 1723 return flags; |
1718 } | 1724 } |
1719 | 1725 |
1720 } // namespace compiler | 1726 } // namespace compiler |
1721 } // namespace internal | 1727 } // namespace internal |
1722 } // namespace v8 | 1728 } // namespace v8 |
OLD | NEW |