| 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 593 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 604 | 604 |
| 605 virtual const char* Mnemonic() const = 0; | 605 virtual const char* Mnemonic() const = 0; |
| 606 virtual Opcode opcode() const = 0; | 606 virtual Opcode opcode() const = 0; |
| 607 | 607 |
| 608 // Updated the inferred type of this instruction and returns true if | 608 // Updated the inferred type of this instruction and returns true if |
| 609 // it has changed. | 609 // it has changed. |
| 610 bool UpdateInferredType(); | 610 bool UpdateInferredType(); |
| 611 | 611 |
| 612 virtual HType CalculateInferredType() const; | 612 virtual HType CalculateInferredType() const; |
| 613 | 613 |
| 614 // Helper for type conversions used by normal and phi instructions. | |
| 615 void InsertInputConversion(HInstruction* previous, int index, HType type); | |
| 616 | |
| 617 #ifdef DEBUG | 614 #ifdef DEBUG |
| 618 virtual void Verify() = 0; | 615 virtual void Verify() = 0; |
| 619 #endif | 616 #endif |
| 620 | 617 |
| 621 protected: | 618 protected: |
| 622 // This function must be overridden for instructions with flag kUseGVN, to | 619 // This function must be overridden for instructions with flag kUseGVN, to |
| 623 // compare the non-Operand parts of the instruction. | 620 // compare the non-Operand parts of the instruction. |
| 624 virtual bool DataEquals(HValue* other) const { | 621 virtual bool DataEquals(HValue* other) const { |
| 625 UNREACHABLE(); | 622 UNREACHABLE(); |
| 626 return false; | 623 return false; |
| (...skipping 2790 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3417 HValue* object() const { return left(); } | 3414 HValue* object() const { return left(); } |
| 3418 HValue* key() const { return right(); } | 3415 HValue* key() const { return right(); } |
| 3419 }; | 3416 }; |
| 3420 | 3417 |
| 3421 #undef DECLARE_INSTRUCTION | 3418 #undef DECLARE_INSTRUCTION |
| 3422 #undef DECLARE_CONCRETE_INSTRUCTION | 3419 #undef DECLARE_CONCRETE_INSTRUCTION |
| 3423 | 3420 |
| 3424 } } // namespace v8::internal | 3421 } } // namespace v8::internal |
| 3425 | 3422 |
| 3426 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 3423 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
| OLD | NEW |