Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 115 V(JSArrayLength) \ | 115 V(JSArrayLength) \ |
| 116 V(Label) \ | 116 V(Label) \ |
| 117 V(LazyBailout) \ | 117 V(LazyBailout) \ |
| 118 V(LoadContextSlot) \ | 118 V(LoadContextSlot) \ |
| 119 V(LoadElements) \ | 119 V(LoadElements) \ |
| 120 V(LoadExternalArrayPointer) \ | 120 V(LoadExternalArrayPointer) \ |
| 121 V(LoadFunctionPrototype) \ | 121 V(LoadFunctionPrototype) \ |
| 122 V(LoadGlobal) \ | 122 V(LoadGlobal) \ |
| 123 V(LoadKeyedFastElement) \ | 123 V(LoadKeyedFastElement) \ |
| 124 V(LoadKeyedGeneric) \ | 124 V(LoadKeyedGeneric) \ |
| 125 V(LoadKeyedSpecializedArrayElement) \ | |
| 125 V(LoadNamedField) \ | 126 V(LoadNamedField) \ |
| 126 V(LoadNamedGeneric) \ | 127 V(LoadNamedGeneric) \ |
| 127 V(LoadPixelArrayElement) \ | |
| 128 V(ModI) \ | 128 V(ModI) \ |
| 129 V(MulI) \ | 129 V(MulI) \ |
| 130 V(NumberTagD) \ | 130 V(NumberTagD) \ |
| 131 V(NumberTagI) \ | 131 V(NumberTagI) \ |
| 132 V(NumberUntagD) \ | 132 V(NumberUntagD) \ |
| 133 V(ObjectLiteral) \ | 133 V(ObjectLiteral) \ |
| 134 V(OsrEntry) \ | 134 V(OsrEntry) \ |
| 135 V(OuterContext) \ | 135 V(OuterContext) \ |
| 136 V(Parameter) \ | 136 V(Parameter) \ |
| 137 V(Power) \ | 137 V(Power) \ |
| 138 V(PushArgument) \ | 138 V(PushArgument) \ |
| 139 V(RegExpLiteral) \ | 139 V(RegExpLiteral) \ |
| 140 V(Return) \ | 140 V(Return) \ |
| 141 V(ShiftI) \ | 141 V(ShiftI) \ |
| 142 V(SmiTag) \ | 142 V(SmiTag) \ |
| 143 V(SmiUntag) \ | 143 V(SmiUntag) \ |
| 144 V(StackCheck) \ | 144 V(StackCheck) \ |
| 145 V(StoreContextSlot) \ | 145 V(StoreContextSlot) \ |
| 146 V(StoreGlobal) \ | 146 V(StoreGlobal) \ |
| 147 V(StoreKeyedFastElement) \ | 147 V(StoreKeyedFastElement) \ |
| 148 V(StoreKeyedGeneric) \ | 148 V(StoreKeyedGeneric) \ |
| 149 V(StoreKeyedSpecializedArrayElement) \ | |
| 149 V(StoreNamedField) \ | 150 V(StoreNamedField) \ |
| 150 V(StoreNamedGeneric) \ | 151 V(StoreNamedGeneric) \ |
| 151 V(StorePixelArrayElement) \ | |
| 152 V(StringCharCodeAt) \ | 152 V(StringCharCodeAt) \ |
| 153 V(StringCharFromCode) \ | 153 V(StringCharFromCode) \ |
| 154 V(StringLength) \ | 154 V(StringLength) \ |
| 155 V(SubI) \ | 155 V(SubI) \ |
| 156 V(TaggedToI) \ | 156 V(TaggedToI) \ |
| 157 V(Throw) \ | 157 V(Throw) \ |
| 158 V(ToFastProperties) \ | 158 V(ToFastProperties) \ |
| 159 V(Typeof) \ | 159 V(Typeof) \ |
| 160 V(TypeofIs) \ | 160 V(TypeofIs) \ |
| 161 V(TypeofIsAndBranch) \ | 161 V(TypeofIsAndBranch) \ |
| (...skipping 1042 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1204 } | 1204 } |
| 1205 | 1205 |
| 1206 DECLARE_CONCRETE_INSTRUCTION(LoadKeyedFastElement, "load-keyed-fast-element") | 1206 DECLARE_CONCRETE_INSTRUCTION(LoadKeyedFastElement, "load-keyed-fast-element") |
| 1207 DECLARE_HYDROGEN_ACCESSOR(LoadKeyedFastElement) | 1207 DECLARE_HYDROGEN_ACCESSOR(LoadKeyedFastElement) |
| 1208 | 1208 |
| 1209 LOperand* elements() { return inputs_[0]; } | 1209 LOperand* elements() { return inputs_[0]; } |
| 1210 LOperand* key() { return inputs_[1]; } | 1210 LOperand* key() { return inputs_[1]; } |
| 1211 }; | 1211 }; |
| 1212 | 1212 |
| 1213 | 1213 |
| 1214 class LLoadPixelArrayElement: public LTemplateInstruction<1, 2, 0> { | 1214 class LLoadKeyedSpecializedArrayElement: public LTemplateInstruction<1, 2, 0> { |
| 1215 public: | 1215 public: |
| 1216 LLoadPixelArrayElement(LOperand* external_pointer, LOperand* key) { | 1216 LLoadKeyedSpecializedArrayElement(LOperand* external_pointer, |
| 1217 LOperand* key, | |
| 1218 ExternalArrayType array_type) | |
| 1219 : array_type_(array_type) { | |
| 1217 inputs_[0] = external_pointer; | 1220 inputs_[0] = external_pointer; |
| 1218 inputs_[1] = key; | 1221 inputs_[1] = key; |
| 1219 } | 1222 } |
| 1220 | 1223 |
| 1221 DECLARE_CONCRETE_INSTRUCTION(LoadPixelArrayElement, | 1224 DECLARE_CONCRETE_INSTRUCTION(LoadKeyedSpecializedArrayElement, |
| 1222 "load-pixel-array-element") | 1225 "load-keyed-specialized-array-element") |
| 1223 DECLARE_HYDROGEN_ACCESSOR(LoadPixelArrayElement) | 1226 DECLARE_HYDROGEN_ACCESSOR(LoadKeyedSpecializedArrayElement) |
| 1224 | 1227 |
| 1225 LOperand* external_pointer() { return inputs_[0]; } | 1228 LOperand* external_pointer() { return inputs_[0]; } |
| 1226 LOperand* key() { return inputs_[1]; } | 1229 LOperand* key() { return inputs_[1]; } |
| 1230 ExternalArrayType array_type() const { return array_type_; } | |
|
Kevin Millikin (Chromium)
2011/03/24 11:21:00
The hydrogen instruction has the array type. You
danno
2011/03/24 13:18:38
Done.
| |
| 1231 | |
| 1232 private: | |
| 1233 ExternalArrayType array_type_; | |
| 1227 }; | 1234 }; |
| 1228 | 1235 |
| 1229 | 1236 |
| 1230 class LLoadKeyedGeneric: public LTemplateInstruction<1, 2, 0> { | 1237 class LLoadKeyedGeneric: public LTemplateInstruction<1, 2, 0> { |
| 1231 public: | 1238 public: |
| 1232 LLoadKeyedGeneric(LOperand* obj, LOperand* key) { | 1239 LLoadKeyedGeneric(LOperand* obj, LOperand* key) { |
| 1233 inputs_[0] = obj; | 1240 inputs_[0] = obj; |
| 1234 inputs_[1] = key; | 1241 inputs_[1] = key; |
| 1235 } | 1242 } |
| 1236 | 1243 |
| (...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1621 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic") | 1628 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric, "store-keyed-generic") |
| 1622 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric) | 1629 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedGeneric) |
| 1623 | 1630 |
| 1624 virtual void PrintDataTo(StringStream* stream); | 1631 virtual void PrintDataTo(StringStream* stream); |
| 1625 | 1632 |
| 1626 LOperand* object() { return inputs_[0]; } | 1633 LOperand* object() { return inputs_[0]; } |
| 1627 LOperand* key() { return inputs_[1]; } | 1634 LOperand* key() { return inputs_[1]; } |
| 1628 LOperand* value() { return inputs_[2]; } | 1635 LOperand* value() { return inputs_[2]; } |
| 1629 }; | 1636 }; |
| 1630 | 1637 |
| 1631 class LStorePixelArrayElement: public LTemplateInstruction<0, 3, 0> { | 1638 class LStoreKeyedSpecializedArrayElement: public LTemplateInstruction<0, 3, 0> { |
| 1632 public: | 1639 public: |
| 1633 LStorePixelArrayElement(LOperand* external_pointer, | 1640 LStoreKeyedSpecializedArrayElement(LOperand* external_pointer, |
| 1634 LOperand* key, | 1641 LOperand* key, |
| 1635 LOperand* val) { | 1642 LOperand* val, |
| 1643 ExternalArrayType array_type) | |
| 1644 : array_type_(array_type) { | |
| 1636 inputs_[0] = external_pointer; | 1645 inputs_[0] = external_pointer; |
| 1637 inputs_[1] = key; | 1646 inputs_[1] = key; |
| 1638 inputs_[2] = val; | 1647 inputs_[2] = val; |
| 1639 } | 1648 } |
| 1640 | 1649 |
| 1641 DECLARE_CONCRETE_INSTRUCTION(StorePixelArrayElement, | 1650 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedSpecializedArrayElement, |
| 1642 "store-pixel-array-element") | 1651 "store-keyed-specialized-array-element") |
| 1643 DECLARE_HYDROGEN_ACCESSOR(StorePixelArrayElement) | 1652 DECLARE_HYDROGEN_ACCESSOR(StoreKeyedSpecializedArrayElement) |
| 1644 | 1653 |
| 1645 LOperand* external_pointer() { return inputs_[0]; } | 1654 LOperand* external_pointer() { return inputs_[0]; } |
| 1646 LOperand* key() { return inputs_[1]; } | 1655 LOperand* key() { return inputs_[1]; } |
| 1647 LOperand* value() { return inputs_[2]; } | 1656 LOperand* value() { return inputs_[2]; } |
| 1657 ExternalArrayType array_type() const { return array_type_; } | |
|
Kevin Millikin (Chromium)
2011/03/24 11:21:00
Also delegate to the hydrogen instruction here.
danno
2011/03/24 13:18:38
Done.
| |
| 1658 | |
| 1659 private: | |
| 1660 ExternalArrayType array_type_; | |
| 1648 }; | 1661 }; |
| 1649 | 1662 |
| 1663 | |
| 1650 class LStringCharCodeAt: public LTemplateInstruction<1, 2, 0> { | 1664 class LStringCharCodeAt: public LTemplateInstruction<1, 2, 0> { |
| 1651 public: | 1665 public: |
| 1652 LStringCharCodeAt(LOperand* string, LOperand* index) { | 1666 LStringCharCodeAt(LOperand* string, LOperand* index) { |
| 1653 inputs_[0] = string; | 1667 inputs_[0] = string; |
| 1654 inputs_[1] = index; | 1668 inputs_[1] = index; |
| 1655 } | 1669 } |
| 1656 | 1670 |
| 1657 DECLARE_CONCRETE_INSTRUCTION(StringCharCodeAt, "string-char-code-at") | 1671 DECLARE_CONCRETE_INSTRUCTION(StringCharCodeAt, "string-char-code-at") |
| 1658 DECLARE_HYDROGEN_ACCESSOR(StringCharCodeAt) | 1672 DECLARE_HYDROGEN_ACCESSOR(StringCharCodeAt) |
| 1659 | 1673 |
| (...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2114 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2128 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
| 2115 }; | 2129 }; |
| 2116 | 2130 |
| 2117 #undef DECLARE_HYDROGEN_ACCESSOR | 2131 #undef DECLARE_HYDROGEN_ACCESSOR |
| 2118 #undef DECLARE_INSTRUCTION | 2132 #undef DECLARE_INSTRUCTION |
| 2119 #undef DECLARE_CONCRETE_INSTRUCTION | 2133 #undef DECLARE_CONCRETE_INSTRUCTION |
| 2120 | 2134 |
| 2121 } } // namespace v8::internal | 2135 } } // namespace v8::internal |
| 2122 | 2136 |
| 2123 #endif // V8_ARM_LITHIUM_ARM_H_ | 2137 #endif // V8_ARM_LITHIUM_ARM_H_ |
| OLD | NEW |