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 924 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
935 | 935 |
936 void InstructionSelector::VisitWord32Ctz(Node* node) { UNREACHABLE(); } | 936 void InstructionSelector::VisitWord32Ctz(Node* node) { UNREACHABLE(); } |
937 | 937 |
938 | 938 |
939 void InstructionSelector::VisitWord64Ctz(Node* node) { UNREACHABLE(); } | 939 void InstructionSelector::VisitWord64Ctz(Node* node) { UNREACHABLE(); } |
940 | 940 |
941 | 941 |
942 void InstructionSelector::VisitWord32Popcnt(Node* node) { UNREACHABLE(); } | 942 void InstructionSelector::VisitWord32Popcnt(Node* node) { UNREACHABLE(); } |
943 | 943 |
944 | 944 |
| 945 void InstructionSelector::VisitWord64Popcnt(Node* node) { UNREACHABLE(); } |
| 946 |
| 947 |
945 void InstructionSelector::VisitInt32Add(Node* node) { | 948 void InstructionSelector::VisitInt32Add(Node* node) { |
946 Arm64OperandGenerator g(this); | 949 Arm64OperandGenerator g(this); |
947 Int32BinopMatcher m(node); | 950 Int32BinopMatcher m(node); |
948 // Select Madd(x, y, z) for Add(Mul(x, y), z). | 951 // Select Madd(x, y, z) for Add(Mul(x, y), z). |
949 if (m.left().IsInt32Mul() && CanCover(node, m.left().node())) { | 952 if (m.left().IsInt32Mul() && CanCover(node, m.left().node())) { |
950 Int32BinopMatcher mleft(m.left().node()); | 953 Int32BinopMatcher mleft(m.left().node()); |
951 // Check multiply can't be later reduced to addition with shift. | 954 // Check multiply can't be later reduced to addition with shift. |
952 if (LeftShiftForReducedMultiply(&mleft) == 0) { | 955 if (LeftShiftForReducedMultiply(&mleft) == 0) { |
953 Emit(kArm64Madd32, g.DefineAsRegister(node), | 956 Emit(kArm64Madd32, g.DefineAsRegister(node), |
954 g.UseRegister(mleft.left().node()), | 957 g.UseRegister(mleft.left().node()), |
(...skipping 1054 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2009 MachineOperatorBuilder::kFloat64RoundTruncate | | 2012 MachineOperatorBuilder::kFloat64RoundTruncate | |
2010 MachineOperatorBuilder::kFloat64RoundTiesAway | | 2013 MachineOperatorBuilder::kFloat64RoundTiesAway | |
2011 MachineOperatorBuilder::kWord32ShiftIsSafe | | 2014 MachineOperatorBuilder::kWord32ShiftIsSafe | |
2012 MachineOperatorBuilder::kInt32DivIsSafe | | 2015 MachineOperatorBuilder::kInt32DivIsSafe | |
2013 MachineOperatorBuilder::kUint32DivIsSafe; | 2016 MachineOperatorBuilder::kUint32DivIsSafe; |
2014 } | 2017 } |
2015 | 2018 |
2016 } // namespace compiler | 2019 } // namespace compiler |
2017 } // namespace internal | 2020 } // namespace internal |
2018 } // namespace v8 | 2021 } // namespace v8 |
OLD | NEW |