| 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 2592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2603 | 2603 |
| 2604 virtual Representation RequiredInputRepresentation(int index) { | 2604 virtual Representation RequiredInputRepresentation(int index) { |
| 2605 return Representation::None(); | 2605 return Representation::None(); |
| 2606 } | 2606 } |
| 2607 | 2607 |
| 2608 virtual bool IsConvertibleToInteger() const { | 2608 virtual bool IsConvertibleToInteger() const { |
| 2609 return has_int32_value_; | 2609 return has_int32_value_; |
| 2610 } | 2610 } |
| 2611 | 2611 |
| 2612 virtual bool EmitAtUses() { return !representation().IsDouble(); } | 2612 virtual bool EmitAtUses() { return !representation().IsDouble(); } |
| 2613 virtual HValue* Canonicalize(); | |
| 2614 virtual void PrintDataTo(StringStream* stream); | 2613 virtual void PrintDataTo(StringStream* stream); |
| 2615 virtual HType CalculateInferredType(); | 2614 virtual HType CalculateInferredType(); |
| 2616 bool IsInteger() { return handle()->IsSmi(); } | 2615 bool IsInteger() { return handle()->IsSmi(); } |
| 2617 HConstant* CopyToRepresentation(Representation r, Zone* zone) const; | 2616 HConstant* CopyToRepresentation(Representation r, Zone* zone) const; |
| 2618 HConstant* CopyToTruncatedInt32(Zone* zone) const; | 2617 HConstant* CopyToTruncatedInt32(Zone* zone) const; |
| 2619 bool HasInteger32Value() const { return has_int32_value_; } | 2618 bool HasInteger32Value() const { return has_int32_value_; } |
| 2620 int32_t Integer32Value() const { | 2619 int32_t Integer32Value() const { |
| 2621 ASSERT(HasInteger32Value()); | 2620 ASSERT(HasInteger32Value()); |
| 2622 return int32_value_; | 2621 return int32_value_; |
| 2623 } | 2622 } |
| (...skipping 2403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5027 public: | 5026 public: |
| 5028 explicit HTypeof(HValue* context, HValue* value) { | 5027 explicit HTypeof(HValue* context, HValue* value) { |
| 5029 SetOperandAt(0, context); | 5028 SetOperandAt(0, context); |
| 5030 SetOperandAt(1, value); | 5029 SetOperandAt(1, value); |
| 5031 set_representation(Representation::Tagged()); | 5030 set_representation(Representation::Tagged()); |
| 5032 } | 5031 } |
| 5033 | 5032 |
| 5034 HValue* context() { return OperandAt(0); } | 5033 HValue* context() { return OperandAt(0); } |
| 5035 HValue* value() { return OperandAt(1); } | 5034 HValue* value() { return OperandAt(1); } |
| 5036 | 5035 |
| 5037 virtual HValue* Canonicalize(); | |
| 5038 virtual void PrintDataTo(StringStream* stream); | 5036 virtual void PrintDataTo(StringStream* stream); |
| 5039 | 5037 |
| 5040 virtual Representation RequiredInputRepresentation(int index) { | 5038 virtual Representation RequiredInputRepresentation(int index) { |
| 5041 return Representation::Tagged(); | 5039 return Representation::Tagged(); |
| 5042 } | 5040 } |
| 5043 | 5041 |
| 5044 DECLARE_CONCRETE_INSTRUCTION(Typeof) | 5042 DECLARE_CONCRETE_INSTRUCTION(Typeof) |
| 5045 | 5043 |
| 5046 private: | 5044 private: |
| 5047 virtual bool IsDeletable() const { return true; } | 5045 virtual bool IsDeletable() const { return true; } |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5284 virtual bool IsDeletable() const { return true; } | 5282 virtual bool IsDeletable() const { return true; } |
| 5285 }; | 5283 }; |
| 5286 | 5284 |
| 5287 | 5285 |
| 5288 #undef DECLARE_INSTRUCTION | 5286 #undef DECLARE_INSTRUCTION |
| 5289 #undef DECLARE_CONCRETE_INSTRUCTION | 5287 #undef DECLARE_CONCRETE_INSTRUCTION |
| 5290 | 5288 |
| 5291 } } // namespace v8::internal | 5289 } } // namespace v8::internal |
| 5292 | 5290 |
| 5293 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 5291 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
| OLD | NEW |