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 2752 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2763 return Representation::Tagged(); | 2763 return Representation::Tagged(); |
2764 } | 2764 } |
2765 virtual bool HandleSideEffectDominator(GVNFlag side_effect, | 2765 virtual bool HandleSideEffectDominator(GVNFlag side_effect, |
2766 HValue* dominator) V8_OVERRIDE; | 2766 HValue* dominator) V8_OVERRIDE; |
2767 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; | 2767 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; |
2768 | 2768 |
2769 HValue* value() { return OperandAt(0); } | 2769 HValue* value() { return OperandAt(0); } |
2770 HValue* typecheck() { return OperandAt(1); } | 2770 HValue* typecheck() { return OperandAt(1); } |
2771 | 2771 |
2772 Unique<Map> first_map() const { return map_set_.at(0); } | 2772 Unique<Map> first_map() const { return map_set_.at(0); } |
2773 UniqueSet<Map> map_set() const { return map_set_; } | 2773 const UniqueSet<Map>* map_set() const { return &map_set_; } |
2774 | 2774 |
2775 void set_map_set(UniqueSet<Map>* maps, Zone *zone) { | 2775 void set_map_set(UniqueSet<Map>* maps, Zone *zone) { |
2776 map_set_.Clear(); | 2776 map_set_.Clear(); |
2777 for (int i = 0; i < maps->size(); i++) { | 2777 for (int i = 0; i < maps->size(); i++) { |
2778 map_set_.Add(maps->at(i), zone); | 2778 map_set_.Add(maps->at(i), zone); |
2779 } | 2779 } |
2780 } | 2780 } |
2781 | 2781 |
2782 bool has_migration_target() const { | 2782 bool has_migration_target() const { |
2783 return has_migration_target_; | 2783 return has_migration_target_; |
(...skipping 3381 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6165 HValue* dependency() { | 6165 HValue* dependency() { |
6166 ASSERT(HasDependency()); | 6166 ASSERT(HasDependency()); |
6167 return OperandAt(1); | 6167 return OperandAt(1); |
6168 } | 6168 } |
6169 bool HasDependency() const { return OperandAt(0) != OperandAt(1); } | 6169 bool HasDependency() const { return OperandAt(0) != OperandAt(1); } |
6170 HObjectAccess access() const { return access_; } | 6170 HObjectAccess access() const { return access_; } |
6171 Representation field_representation() const { | 6171 Representation field_representation() const { |
6172 return access_.representation(); | 6172 return access_.representation(); |
6173 } | 6173 } |
6174 | 6174 |
6175 UniqueSet<Map> map_set() const { return map_set_; } | 6175 const UniqueSet<Map>* map_set() const { return &map_set_; } |
6176 | 6176 |
6177 virtual bool HasEscapingOperandAt(int index) V8_OVERRIDE { return false; } | 6177 virtual bool HasEscapingOperandAt(int index) V8_OVERRIDE { return false; } |
6178 virtual bool HasOutOfBoundsAccess(int size) V8_OVERRIDE { | 6178 virtual bool HasOutOfBoundsAccess(int size) V8_OVERRIDE { |
6179 return !access().IsInobject() || access().offset() >= size; | 6179 return !access().IsInobject() || access().offset() >= size; |
6180 } | 6180 } |
6181 virtual Representation RequiredInputRepresentation(int index) V8_OVERRIDE { | 6181 virtual Representation RequiredInputRepresentation(int index) V8_OVERRIDE { |
6182 if (index == 0 && access().IsExternalMemory()) { | 6182 if (index == 0 && access().IsExternalMemory()) { |
6183 // object must be external in case of external memory access | 6183 // object must be external in case of external memory access |
6184 return Representation::External(); | 6184 return Representation::External(); |
6185 } | 6185 } |
(...skipping 1375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7561 virtual bool IsDeletable() const V8_OVERRIDE { return true; } | 7561 virtual bool IsDeletable() const V8_OVERRIDE { return true; } |
7562 }; | 7562 }; |
7563 | 7563 |
7564 | 7564 |
7565 #undef DECLARE_INSTRUCTION | 7565 #undef DECLARE_INSTRUCTION |
7566 #undef DECLARE_CONCRETE_INSTRUCTION | 7566 #undef DECLARE_CONCRETE_INSTRUCTION |
7567 | 7567 |
7568 } } // namespace v8::internal | 7568 } } // namespace v8::internal |
7569 | 7569 |
7570 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 7570 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
OLD | NEW |