| 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 863 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 874 | 874 |
| 875 Node* success_output = NodeProperties::FindProjection(node, 1); | 875 Node* success_output = NodeProperties::FindProjection(node, 1); |
| 876 if (success_output) { | 876 if (success_output) { |
| 877 outputs[output_count++] = g.DefineAsRegister(success_output); | 877 outputs[output_count++] = g.DefineAsRegister(success_output); |
| 878 } | 878 } |
| 879 | 879 |
| 880 Emit(kMips64TruncLD, output_count, outputs, 1, inputs); | 880 Emit(kMips64TruncLD, output_count, outputs, 1, inputs); |
| 881 } | 881 } |
| 882 | 882 |
| 883 | 883 |
| 884 void InstructionSelector::VisitTruncateFloat32ToUint64(Node* node) { | 884 void InstructionSelector::VisitTryTruncateFloat32ToUint64(Node* node) { |
| 885 VisitRR(this, kMips64TruncUlS, node); | 885 Mips64OperandGenerator g(this); |
| 886 InstructionOperand inputs[] = {g.UseRegister(node->InputAt(0))}; |
| 887 InstructionOperand outputs[2]; |
| 888 size_t output_count = 0; |
| 889 outputs[output_count++] = g.DefineAsRegister(node); |
| 890 |
| 891 Node* success_output = NodeProperties::FindProjection(node, 1); |
| 892 if (success_output) { |
| 893 outputs[output_count++] = g.DefineAsRegister(success_output); |
| 894 } |
| 895 |
| 896 Emit(kMips64TruncUlS, output_count, outputs, 1, inputs); |
| 886 } | 897 } |
| 887 | 898 |
| 888 | 899 |
| 889 void InstructionSelector::VisitTryTruncateFloat64ToUint64(Node* node) { | 900 void InstructionSelector::VisitTryTruncateFloat64ToUint64(Node* node) { |
| 890 Mips64OperandGenerator g(this); | 901 Mips64OperandGenerator g(this); |
| 891 | 902 |
| 892 InstructionOperand inputs[] = {g.UseRegister(node->InputAt(0))}; | 903 InstructionOperand inputs[] = {g.UseRegister(node->InputAt(0))}; |
| 893 InstructionOperand outputs[2]; | 904 InstructionOperand outputs[2]; |
| 894 size_t output_count = 0; | 905 size_t output_count = 0; |
| 895 outputs[output_count++] = g.DefineAsRegister(node); | 906 outputs[output_count++] = g.DefineAsRegister(node); |
| (...skipping 880 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1776 MachineOperatorBuilder::kFloat32RoundUp | | 1787 MachineOperatorBuilder::kFloat32RoundUp | |
| 1777 MachineOperatorBuilder::kFloat64RoundTruncate | | 1788 MachineOperatorBuilder::kFloat64RoundTruncate | |
| 1778 MachineOperatorBuilder::kFloat32RoundTruncate | | 1789 MachineOperatorBuilder::kFloat32RoundTruncate | |
| 1779 MachineOperatorBuilder::kFloat64RoundTiesEven | | 1790 MachineOperatorBuilder::kFloat64RoundTiesEven | |
| 1780 MachineOperatorBuilder::kFloat32RoundTiesEven; | 1791 MachineOperatorBuilder::kFloat32RoundTiesEven; |
| 1781 } | 1792 } |
| 1782 | 1793 |
| 1783 } // namespace compiler | 1794 } // namespace compiler |
| 1784 } // namespace internal | 1795 } // namespace internal |
| 1785 } // namespace v8 | 1796 } // namespace v8 |
| OLD | NEW |