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/base/adapters.h" | 5 #include "src/base/adapters.h" |
6 #include "src/base/bits.h" | 6 #include "src/base/bits.h" |
7 #include "src/compiler/instruction-selector-impl.h" | 7 #include "src/compiler/instruction-selector-impl.h" |
8 #include "src/compiler/node-matchers.h" | 8 #include "src/compiler/node-matchers.h" |
9 #include "src/compiler/node-properties.h" | 9 #include "src/compiler/node-properties.h" |
10 | 10 |
(...skipping 781 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
792 g.UseRegister(node->InputAt(0)), g.UseUniqueRegister(node->InputAt(1)), | 792 g.UseRegister(node->InputAt(0)), g.UseUniqueRegister(node->InputAt(1)), |
793 g.UseRegister(node->InputAt(2)), g.UseUniqueRegister(node->InputAt(3))}; | 793 g.UseRegister(node->InputAt(2)), g.UseUniqueRegister(node->InputAt(3))}; |
794 | 794 |
795 InstructionOperand outputs[] = { | 795 InstructionOperand outputs[] = { |
796 g.DefineAsRegister(node), | 796 g.DefineAsRegister(node), |
797 g.DefineAsRegister(NodeProperties::FindProjection(node, 1))}; | 797 g.DefineAsRegister(NodeProperties::FindProjection(node, 1))}; |
798 | 798 |
799 Emit(kArmSubPair, 2, outputs, 4, inputs); | 799 Emit(kArmSubPair, 2, outputs, 4, inputs); |
800 } | 800 } |
801 | 801 |
| 802 void InstructionSelector::VisitInt32PairMul(Node* node) { |
| 803 ArmOperandGenerator g(this); |
| 804 InstructionOperand inputs[] = {g.UseUniqueRegister(node->InputAt(0)), |
| 805 g.UseUniqueRegister(node->InputAt(1)), |
| 806 g.UseUniqueRegister(node->InputAt(2)), |
| 807 g.UseUniqueRegister(node->InputAt(3))}; |
| 808 |
| 809 InstructionOperand outputs[] = { |
| 810 g.DefineAsRegister(node), |
| 811 g.DefineAsRegister(NodeProperties::FindProjection(node, 1))}; |
| 812 |
| 813 Emit(kArmMulPair, 2, outputs, 4, inputs); |
| 814 } |
| 815 |
802 void InstructionSelector::VisitWord32PairShl(Node* node) { | 816 void InstructionSelector::VisitWord32PairShl(Node* node) { |
803 ArmOperandGenerator g(this); | 817 ArmOperandGenerator g(this); |
804 // We use g.UseUniqueRegister here for InputAt(0) to guarantee that there is | 818 // We use g.UseUniqueRegister here for InputAt(0) to guarantee that there is |
805 // no register aliasing with output registers. | 819 // no register aliasing with output registers. |
806 Int32Matcher m(node->InputAt(2)); | 820 Int32Matcher m(node->InputAt(2)); |
807 InstructionOperand shift_operand; | 821 InstructionOperand shift_operand; |
808 if (m.HasValue()) { | 822 if (m.HasValue()) { |
809 shift_operand = g.UseImmediate(m.node()); | 823 shift_operand = g.UseImmediate(m.node()); |
810 } else { | 824 } else { |
811 shift_operand = g.UseUniqueRegister(m.node()); | 825 shift_operand = g.UseUniqueRegister(m.node()); |
(...skipping 999 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1811 MachineOperatorBuilder::kFloat64RoundTiesAway | | 1825 MachineOperatorBuilder::kFloat64RoundTiesAway | |
1812 MachineOperatorBuilder::kFloat32RoundTiesEven | | 1826 MachineOperatorBuilder::kFloat32RoundTiesEven | |
1813 MachineOperatorBuilder::kFloat64RoundTiesEven; | 1827 MachineOperatorBuilder::kFloat64RoundTiesEven; |
1814 } | 1828 } |
1815 return flags; | 1829 return flags; |
1816 } | 1830 } |
1817 | 1831 |
1818 } // namespace compiler | 1832 } // namespace compiler |
1819 } // namespace internal | 1833 } // namespace internal |
1820 } // namespace v8 | 1834 } // namespace v8 |
OLD | NEW |