| 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 4306 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4317 virtual Representation RequiredInputRepresentation(int index) V8_OVERRIDE { | 4317 virtual Representation RequiredInputRepresentation(int index) V8_OVERRIDE { |
| 4318 return Representation::None(); | 4318 return Representation::None(); |
| 4319 } | 4319 } |
| 4320 | 4320 |
| 4321 DECLARE_CONCRETE_INSTRUCTION(IsConstructCallAndBranch) | 4321 DECLARE_CONCRETE_INSTRUCTION(IsConstructCallAndBranch) |
| 4322 }; | 4322 }; |
| 4323 | 4323 |
| 4324 | 4324 |
| 4325 class HHasInstanceTypeAndBranch V8_FINAL : public HUnaryControlInstruction { | 4325 class HHasInstanceTypeAndBranch V8_FINAL : public HUnaryControlInstruction { |
| 4326 public: | 4326 public: |
| 4327 HHasInstanceTypeAndBranch(HValue* value, InstanceType type) | 4327 DECLARE_INSTRUCTION_FACTORY_P2( |
| 4328 : HUnaryControlInstruction(value, NULL, NULL), from_(type), to_(type) { } | 4328 HHasInstanceTypeAndBranch, HValue*, InstanceType); |
| 4329 HHasInstanceTypeAndBranch(HValue* value, InstanceType from, InstanceType to) | 4329 DECLARE_INSTRUCTION_FACTORY_P3( |
| 4330 : HUnaryControlInstruction(value, NULL, NULL), from_(from), to_(to) { | 4330 HHasInstanceTypeAndBranch, HValue*, InstanceType, InstanceType); |
| 4331 ASSERT(to == LAST_TYPE); // Others not implemented yet in backend. | |
| 4332 } | |
| 4333 | 4331 |
| 4334 InstanceType from() { return from_; } | 4332 InstanceType from() { return from_; } |
| 4335 InstanceType to() { return to_; } | 4333 InstanceType to() { return to_; } |
| 4336 | 4334 |
| 4337 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; | 4335 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; |
| 4338 | 4336 |
| 4339 virtual Representation RequiredInputRepresentation(int index) V8_OVERRIDE { | 4337 virtual Representation RequiredInputRepresentation(int index) V8_OVERRIDE { |
| 4340 return Representation::Tagged(); | 4338 return Representation::Tagged(); |
| 4341 } | 4339 } |
| 4342 | 4340 |
| 4343 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch) | 4341 DECLARE_CONCRETE_INSTRUCTION(HasInstanceTypeAndBranch) |
| 4344 | 4342 |
| 4345 private: | 4343 private: |
| 4344 HHasInstanceTypeAndBranch(HValue* value, InstanceType type) |
| 4345 : HUnaryControlInstruction(value, NULL, NULL), from_(type), to_(type) { } |
| 4346 HHasInstanceTypeAndBranch(HValue* value, InstanceType from, InstanceType to) |
| 4347 : HUnaryControlInstruction(value, NULL, NULL), from_(from), to_(to) { |
| 4348 ASSERT(to == LAST_TYPE); // Others not implemented yet in backend. |
| 4349 } |
| 4350 |
| 4346 InstanceType from_; | 4351 InstanceType from_; |
| 4347 InstanceType to_; // Inclusive range, not all combinations work. | 4352 InstanceType to_; // Inclusive range, not all combinations work. |
| 4348 }; | 4353 }; |
| 4349 | 4354 |
| 4350 | 4355 |
| 4351 class HHasCachedArrayIndexAndBranch V8_FINAL : public HUnaryControlInstruction { | 4356 class HHasCachedArrayIndexAndBranch V8_FINAL : public HUnaryControlInstruction { |
| 4352 public: | 4357 public: |
| 4353 explicit HHasCachedArrayIndexAndBranch(HValue* value) | 4358 explicit HHasCachedArrayIndexAndBranch(HValue* value) |
| 4354 : HUnaryControlInstruction(value, NULL, NULL) { } | 4359 : HUnaryControlInstruction(value, NULL, NULL) { } |
| 4355 | 4360 |
| (...skipping 2763 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7119 virtual bool IsDeletable() const V8_OVERRIDE { return true; } | 7124 virtual bool IsDeletable() const V8_OVERRIDE { return true; } |
| 7120 }; | 7125 }; |
| 7121 | 7126 |
| 7122 | 7127 |
| 7123 #undef DECLARE_INSTRUCTION | 7128 #undef DECLARE_INSTRUCTION |
| 7124 #undef DECLARE_CONCRETE_INSTRUCTION | 7129 #undef DECLARE_CONCRETE_INSTRUCTION |
| 7125 | 7130 |
| 7126 } } // namespace v8::internal | 7131 } } // namespace v8::internal |
| 7127 | 7132 |
| 7128 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 7133 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
| OLD | NEW |