OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
174 V(SubI) \ | 174 V(SubI) \ |
175 V(TaggedToI) \ | 175 V(TaggedToI) \ |
176 V(ThisFunction) \ | 176 V(ThisFunction) \ |
177 V(Throw) \ | 177 V(Throw) \ |
178 V(ToFastProperties) \ | 178 V(ToFastProperties) \ |
179 V(TransitionElementsKind) \ | 179 V(TransitionElementsKind) \ |
180 V(TrapAllocationMemento) \ | 180 V(TrapAllocationMemento) \ |
181 V(Typeof) \ | 181 V(Typeof) \ |
182 V(TypeofIsAndBranch) \ | 182 V(TypeofIsAndBranch) \ |
183 V(Uint32ToDouble) \ | 183 V(Uint32ToDouble) \ |
| 184 V(Uint32ToSmi) \ |
184 V(UnknownOSRValue) \ | 185 V(UnknownOSRValue) \ |
185 V(ValueOf) \ | 186 V(ValueOf) \ |
186 V(WrapReceiver) | 187 V(WrapReceiver) |
187 | 188 |
188 | 189 |
189 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ | 190 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ |
190 virtual Opcode opcode() const { return LInstruction::k##type; } \ | 191 virtual Opcode opcode() const { return LInstruction::k##type; } \ |
191 virtual void CompileToNative(LCodeGen* generator); \ | 192 virtual void CompileToNative(LCodeGen* generator); \ |
192 virtual const char* Mnemonic() const { return mnemonic; } \ | 193 virtual const char* Mnemonic() const { return mnemonic; } \ |
193 static L##type* cast(LInstruction* instr) { \ | 194 static L##type* cast(LInstruction* instr) { \ |
(...skipping 1718 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1912 temps_[0] = temp; | 1913 temps_[0] = temp; |
1913 } | 1914 } |
1914 | 1915 |
1915 LOperand* value() { return inputs_[0]; } | 1916 LOperand* value() { return inputs_[0]; } |
1916 LOperand* temp() { return temps_[0]; } | 1917 LOperand* temp() { return temps_[0]; } |
1917 | 1918 |
1918 DECLARE_CONCRETE_INSTRUCTION(Uint32ToDouble, "uint32-to-double") | 1919 DECLARE_CONCRETE_INSTRUCTION(Uint32ToDouble, "uint32-to-double") |
1919 }; | 1920 }; |
1920 | 1921 |
1921 | 1922 |
| 1923 class LUint32ToSmi: public LTemplateInstruction<1, 1, 0> { |
| 1924 public: |
| 1925 explicit LUint32ToSmi(LOperand* value) { |
| 1926 inputs_[0] = value; |
| 1927 } |
| 1928 |
| 1929 LOperand* value() { return inputs_[0]; } |
| 1930 |
| 1931 DECLARE_CONCRETE_INSTRUCTION(Uint32ToSmi, "uint32-to-smi") |
| 1932 DECLARE_HYDROGEN_ACCESSOR(Change) |
| 1933 }; |
| 1934 |
| 1935 |
1922 class LNumberTagI: public LTemplateInstruction<1, 1, 0> { | 1936 class LNumberTagI: public LTemplateInstruction<1, 1, 0> { |
1923 public: | 1937 public: |
1924 explicit LNumberTagI(LOperand* value) { | 1938 explicit LNumberTagI(LOperand* value) { |
1925 inputs_[0] = value; | 1939 inputs_[0] = value; |
1926 } | 1940 } |
1927 | 1941 |
1928 LOperand* value() { return inputs_[0]; } | 1942 LOperand* value() { return inputs_[0]; } |
1929 | 1943 |
1930 DECLARE_CONCRETE_INSTRUCTION(NumberTagI, "number-tag-i") | 1944 DECLARE_CONCRETE_INSTRUCTION(NumberTagI, "number-tag-i") |
1931 }; | 1945 }; |
(...skipping 737 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2669 | 2683 |
2670 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2684 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
2671 }; | 2685 }; |
2672 | 2686 |
2673 #undef DECLARE_HYDROGEN_ACCESSOR | 2687 #undef DECLARE_HYDROGEN_ACCESSOR |
2674 #undef DECLARE_CONCRETE_INSTRUCTION | 2688 #undef DECLARE_CONCRETE_INSTRUCTION |
2675 | 2689 |
2676 } } // namespace v8::int | 2690 } } // namespace v8::int |
2677 | 2691 |
2678 #endif // V8_X64_LITHIUM_X64_H_ | 2692 #endif // V8_X64_LITHIUM_X64_H_ |
OLD | NEW |