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 382 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
393 } | 393 } |
394 | 394 |
395 void RecordUint32Instruction(HInstruction* instr) { | 395 void RecordUint32Instruction(HInstruction* instr) { |
396 if (uint32_instructions_ == NULL) { | 396 if (uint32_instructions_ == NULL) { |
397 uint32_instructions_ = new(zone()) ZoneList<HInstruction*>(4, zone()); | 397 uint32_instructions_ = new(zone()) ZoneList<HInstruction*>(4, zone()); |
398 } | 398 } |
399 uint32_instructions_->Add(instr, zone()); | 399 uint32_instructions_->Add(instr, zone()); |
400 } | 400 } |
401 | 401 |
402 private: | 402 private: |
403 HConstant* GetConstantInt32(SetOncePointer<HConstant>* pointer, | 403 HConstant* GetConstant(SetOncePointer<HConstant>* pointer, |
404 int32_t integer_value); | 404 int32_t integer_value); |
405 | 405 |
406 void MarkLive(HValue* ref, HValue* instr, ZoneList<HValue*>* worklist); | 406 void MarkLive(HValue* ref, HValue* instr, ZoneList<HValue*>* worklist); |
407 void MarkLiveInstructions(); | 407 void MarkLiveInstructions(); |
408 void RemoveDeadInstructions(); | 408 void RemoveDeadInstructions(); |
409 void MarkAsDeoptimizingRecursively(HBasicBlock* block); | 409 void MarkAsDeoptimizingRecursively(HBasicBlock* block); |
410 void NullifyUnreachableInstructions(); | 410 void NullifyUnreachableInstructions(); |
411 void InsertTypeConversions(HInstruction* instr); | 411 void InsertTypeConversions(HInstruction* instr); |
412 void PropagateMinusZeroChecks(HValue* value, BitVector* visited); | 412 void PropagateMinusZeroChecks(HValue* value, BitVector* visited); |
413 void RecursivelyMarkPhiDeoptimizeOnUndefined(HPhi* phi); | 413 void RecursivelyMarkPhiDeoptimizeOnUndefined(HPhi* phi); |
414 void InsertRepresentationChangeForUse(HValue* value, | 414 void InsertRepresentationChangeForUse(HValue* value, |
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
945 HGraph* CreateGraph(); | 945 HGraph* CreateGraph(); |
946 | 946 |
947 // Bailout environment manipulation. | 947 // Bailout environment manipulation. |
948 void Push(HValue* value) { environment()->Push(value); } | 948 void Push(HValue* value) { environment()->Push(value); } |
949 HValue* Pop() { return environment()->Pop(); } | 949 HValue* Pop() { return environment()->Pop(); } |
950 | 950 |
951 // Adding instructions. | 951 // Adding instructions. |
952 HInstruction* AddInstruction(HInstruction* instr); | 952 HInstruction* AddInstruction(HInstruction* instr); |
953 void AddSimulate(BailoutId id, | 953 void AddSimulate(BailoutId id, |
954 RemovableSimulate removable = FIXED_SIMULATE); | 954 RemovableSimulate removable = FIXED_SIMULATE); |
955 HBoundsCheck* AddBoundsCheck( | 955 HBoundsCheck* AddBoundsCheck(HValue* index, HValue* length); |
956 HValue* index, | |
957 HValue* length, | |
958 BoundsCheckKeyMode key_mode = DONT_ALLOW_SMI_KEY); | |
959 | 956 |
960 HReturn* AddReturn(HValue* value); | 957 HReturn* AddReturn(HValue* value); |
961 | 958 |
962 void IncrementInNoSideEffectsScope() { | 959 void IncrementInNoSideEffectsScope() { |
963 no_side_effects_scope_count_++; | 960 no_side_effects_scope_count_++; |
964 } | 961 } |
965 | 962 |
966 void DecrementInNoSideEffectsScope() { | 963 void DecrementInNoSideEffectsScope() { |
967 no_side_effects_scope_count_--; | 964 no_side_effects_scope_count_--; |
968 } | 965 } |
(...skipping 984 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1953 EmbeddedVector<char, 64> filename_; | 1950 EmbeddedVector<char, 64> filename_; |
1954 HeapStringAllocator string_allocator_; | 1951 HeapStringAllocator string_allocator_; |
1955 StringStream trace_; | 1952 StringStream trace_; |
1956 int indent_; | 1953 int indent_; |
1957 }; | 1954 }; |
1958 | 1955 |
1959 | 1956 |
1960 } } // namespace v8::internal | 1957 } } // namespace v8::internal |
1961 | 1958 |
1962 #endif // V8_HYDROGEN_H_ | 1959 #endif // V8_HYDROGEN_H_ |
OLD | NEW |