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 2820 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2831 SetFlag(kUseGVN); | 2831 SetFlag(kUseGVN); |
2832 target_in_new_space_ = Isolate::Current()->heap()->InNewSpace(*function); | 2832 target_in_new_space_ = Isolate::Current()->heap()->InNewSpace(*function); |
2833 } | 2833 } |
2834 | 2834 |
2835 virtual Representation RequiredInputRepresentation(int index) { | 2835 virtual Representation RequiredInputRepresentation(int index) { |
2836 return Representation::Tagged(); | 2836 return Representation::Tagged(); |
2837 } | 2837 } |
2838 virtual void PrintDataTo(StringStream* stream); | 2838 virtual void PrintDataTo(StringStream* stream); |
2839 virtual HType CalculateInferredType(); | 2839 virtual HType CalculateInferredType(); |
2840 | 2840 |
2841 virtual HValue* Canonicalize(); | |
2842 | |
2843 #ifdef DEBUG | 2841 #ifdef DEBUG |
2844 virtual void Verify(); | 2842 virtual void Verify(); |
2845 #endif | 2843 #endif |
2846 | 2844 |
2847 virtual void FinalizeUniqueValueId() { | 2845 virtual void FinalizeUniqueValueId() { |
2848 target_unique_id_ = UniqueValueId(target_); | 2846 target_unique_id_ = UniqueValueId(target_); |
2849 } | 2847 } |
2850 | 2848 |
2851 Handle<JSFunction> target() const { return target_; } | 2849 Handle<JSFunction> target() const { return target_; } |
2852 bool target_in_new_space() const { return target_in_new_space_; } | 2850 bool target_in_new_space() const { return target_in_new_space_; } |
(...skipping 553 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3406 } | 3404 } |
3407 } | 3405 } |
3408 | 3406 |
3409 virtual void FinalizeUniqueValueId() { | 3407 virtual void FinalizeUniqueValueId() { |
3410 if (!has_double_value_) { | 3408 if (!has_double_value_) { |
3411 ASSERT(!handle_.is_null()); | 3409 ASSERT(!handle_.is_null()); |
3412 unique_id_ = UniqueValueId(handle_); | 3410 unique_id_ = UniqueValueId(handle_); |
3413 } | 3411 } |
3414 } | 3412 } |
3415 | 3413 |
3416 bool UniqueValueIdsMatch(UniqueValueId other) { | |
3417 if (!has_double_value_) return unique_id_ == other; | |
3418 return false; | |
3419 } | |
3420 | |
3421 #ifdef DEBUG | 3414 #ifdef DEBUG |
3422 virtual void Verify() { } | 3415 virtual void Verify() { } |
3423 #endif | 3416 #endif |
3424 | 3417 |
3425 DECLARE_CONCRETE_INSTRUCTION(Constant) | 3418 DECLARE_CONCRETE_INSTRUCTION(Constant) |
3426 | 3419 |
3427 protected: | 3420 protected: |
3428 virtual Range* InferRange(Zone* zone); | 3421 virtual Range* InferRange(Zone* zone); |
3429 | 3422 |
3430 virtual bool DataEquals(HValue* other) { | 3423 virtual bool DataEquals(HValue* other) { |
(...skipping 3279 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6710 virtual bool IsDeletable() const { return true; } | 6703 virtual bool IsDeletable() const { return true; } |
6711 }; | 6704 }; |
6712 | 6705 |
6713 | 6706 |
6714 #undef DECLARE_INSTRUCTION | 6707 #undef DECLARE_INSTRUCTION |
6715 #undef DECLARE_CONCRETE_INSTRUCTION | 6708 #undef DECLARE_CONCRETE_INSTRUCTION |
6716 | 6709 |
6717 } } // namespace v8::internal | 6710 } } // namespace v8::internal |
6718 | 6711 |
6719 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 6712 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
OLD | NEW |