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 3293 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3304 PropertyDetails details_; | 3304 PropertyDetails details_; |
3305 }; | 3305 }; |
3306 | 3306 |
3307 | 3307 |
3308 class HStoreGlobalGeneric: public HTemplateInstruction<3> { | 3308 class HStoreGlobalGeneric: public HTemplateInstruction<3> { |
3309 public: | 3309 public: |
3310 HStoreGlobalGeneric(HValue* context, | 3310 HStoreGlobalGeneric(HValue* context, |
3311 HValue* global_object, | 3311 HValue* global_object, |
3312 Handle<Object> name, | 3312 Handle<Object> name, |
3313 HValue* value, | 3313 HValue* value, |
3314 bool strict_mode) | 3314 StrictModeFlag strict_mode_flag) |
3315 : name_(name), | 3315 : name_(name), |
3316 strict_mode_(strict_mode) { | 3316 strict_mode_flag_(strict_mode_flag) { |
3317 SetOperandAt(0, context); | 3317 SetOperandAt(0, context); |
3318 SetOperandAt(1, global_object); | 3318 SetOperandAt(1, global_object); |
3319 SetOperandAt(2, value); | 3319 SetOperandAt(2, value); |
3320 set_representation(Representation::Tagged()); | 3320 set_representation(Representation::Tagged()); |
3321 SetAllSideEffects(); | 3321 SetAllSideEffects(); |
3322 } | 3322 } |
3323 | 3323 |
3324 HValue* context() { return OperandAt(0); } | 3324 HValue* context() { return OperandAt(0); } |
3325 HValue* global_object() { return OperandAt(1); } | 3325 HValue* global_object() { return OperandAt(1); } |
3326 Handle<Object> name() const { return name_; } | 3326 Handle<Object> name() const { return name_; } |
3327 HValue* value() { return OperandAt(2); } | 3327 HValue* value() { return OperandAt(2); } |
3328 bool strict_mode() { return strict_mode_; } | 3328 StrictModeFlag strict_mode_flag() { return strict_mode_flag_; } |
3329 | 3329 |
3330 virtual void PrintDataTo(StringStream* stream); | 3330 virtual void PrintDataTo(StringStream* stream); |
3331 | 3331 |
3332 virtual Representation RequiredInputRepresentation(int index) { | 3332 virtual Representation RequiredInputRepresentation(int index) { |
3333 return Representation::Tagged(); | 3333 return Representation::Tagged(); |
3334 } | 3334 } |
3335 | 3335 |
3336 DECLARE_CONCRETE_INSTRUCTION(StoreGlobalGeneric) | 3336 DECLARE_CONCRETE_INSTRUCTION(StoreGlobalGeneric) |
3337 | 3337 |
3338 private: | 3338 private: |
3339 Handle<Object> name_; | 3339 Handle<Object> name_; |
3340 bool strict_mode_; | 3340 StrictModeFlag strict_mode_flag_; |
3341 }; | 3341 }; |
3342 | 3342 |
3343 | 3343 |
3344 class HLoadContextSlot: public HUnaryOperation { | 3344 class HLoadContextSlot: public HUnaryOperation { |
3345 public: | 3345 public: |
3346 HLoadContextSlot(HValue* context , int slot_index) | 3346 HLoadContextSlot(HValue* context , int slot_index) |
3347 : HUnaryOperation(context), slot_index_(slot_index) { | 3347 : HUnaryOperation(context), slot_index_(slot_index) { |
3348 set_representation(Representation::Tagged()); | 3348 set_representation(Representation::Tagged()); |
3349 SetFlag(kUseGVN); | 3349 SetFlag(kUseGVN); |
3350 SetFlag(kDependsOnContextSlots); | 3350 SetFlag(kDependsOnContextSlots); |
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3860 ElementsKind elements_kind_; | 3860 ElementsKind elements_kind_; |
3861 }; | 3861 }; |
3862 | 3862 |
3863 | 3863 |
3864 class HStoreKeyedGeneric: public HTemplateInstruction<4> { | 3864 class HStoreKeyedGeneric: public HTemplateInstruction<4> { |
3865 public: | 3865 public: |
3866 HStoreKeyedGeneric(HValue* context, | 3866 HStoreKeyedGeneric(HValue* context, |
3867 HValue* object, | 3867 HValue* object, |
3868 HValue* key, | 3868 HValue* key, |
3869 HValue* value, | 3869 HValue* value, |
3870 bool strict_mode) | 3870 StrictModeFlag strict_mode_flag) |
3871 : strict_mode_(strict_mode) { | 3871 : strict_mode_flag_(strict_mode_flag) { |
3872 SetOperandAt(0, object); | 3872 SetOperandAt(0, object); |
3873 SetOperandAt(1, key); | 3873 SetOperandAt(1, key); |
3874 SetOperandAt(2, value); | 3874 SetOperandAt(2, value); |
3875 SetOperandAt(3, context); | 3875 SetOperandAt(3, context); |
3876 SetAllSideEffects(); | 3876 SetAllSideEffects(); |
3877 } | 3877 } |
3878 | 3878 |
3879 HValue* object() { return OperandAt(0); } | 3879 HValue* object() { return OperandAt(0); } |
3880 HValue* key() { return OperandAt(1); } | 3880 HValue* key() { return OperandAt(1); } |
3881 HValue* value() { return OperandAt(2); } | 3881 HValue* value() { return OperandAt(2); } |
3882 HValue* context() { return OperandAt(3); } | 3882 HValue* context() { return OperandAt(3); } |
3883 bool strict_mode() { return strict_mode_; } | 3883 StrictModeFlag strict_mode_flag() { return strict_mode_flag_; } |
3884 | 3884 |
3885 virtual Representation RequiredInputRepresentation(int index) { | 3885 virtual Representation RequiredInputRepresentation(int index) { |
3886 return Representation::Tagged(); | 3886 return Representation::Tagged(); |
3887 } | 3887 } |
3888 | 3888 |
3889 virtual void PrintDataTo(StringStream* stream); | 3889 virtual void PrintDataTo(StringStream* stream); |
3890 | 3890 |
3891 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric) | 3891 DECLARE_CONCRETE_INSTRUCTION(StoreKeyedGeneric) |
3892 | 3892 |
3893 private: | 3893 private: |
3894 bool strict_mode_; | 3894 StrictModeFlag strict_mode_flag_; |
3895 }; | 3895 }; |
3896 | 3896 |
3897 | 3897 |
3898 class HTransitionElementsKind: public HTemplateInstruction<1> { | 3898 class HTransitionElementsKind: public HTemplateInstruction<1> { |
3899 public: | 3899 public: |
3900 HTransitionElementsKind(HValue* object, | 3900 HTransitionElementsKind(HValue* object, |
3901 Handle<Map> original_map, | 3901 Handle<Map> original_map, |
3902 Handle<Map> transitioned_map) | 3902 Handle<Map> transitioned_map) |
3903 : original_map_(original_map), | 3903 : original_map_(original_map), |
3904 transitioned_map_(transitioned_map) { | 3904 transitioned_map_(transitioned_map) { |
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4286 | 4286 |
4287 DECLARE_CONCRETE_INSTRUCTION(In) | 4287 DECLARE_CONCRETE_INSTRUCTION(In) |
4288 }; | 4288 }; |
4289 | 4289 |
4290 #undef DECLARE_INSTRUCTION | 4290 #undef DECLARE_INSTRUCTION |
4291 #undef DECLARE_CONCRETE_INSTRUCTION | 4291 #undef DECLARE_CONCRETE_INSTRUCTION |
4292 | 4292 |
4293 } } // namespace v8::internal | 4293 } } // namespace v8::internal |
4294 | 4294 |
4295 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 4295 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
OLD | NEW |