Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(191)

Side by Side Diff: src/hydrogen.h

Issue 17587008: Refactor Hydrogen environment liveness analysis into an HPhase. (Closed) Base URL: git@github.com:v8/v8.git@master
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | src/hydrogen.cc » ('j') | src/hydrogen-environment-liveness.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 410 matching lines...) Expand 10 before | Expand all | Expand 10 after
421 if (uint32_instructions_ == NULL) { 421 if (uint32_instructions_ == NULL) {
422 uint32_instructions_ = new(zone()) ZoneList<HInstruction*>(4, zone()); 422 uint32_instructions_ = new(zone()) ZoneList<HInstruction*>(4, zone());
423 } 423 }
424 uint32_instructions_->Add(instr, zone()); 424 uint32_instructions_->Add(instr, zone());
425 } 425 }
426 426
427 private: 427 private:
428 HConstant* GetConstant(SetOncePointer<HConstant>* pointer, 428 HConstant* GetConstant(SetOncePointer<HConstant>* pointer,
429 int32_t integer_value); 429 int32_t integer_value);
430 430
431 template<typename Phase>
432 void Run() { Phase phase(this, info()->phase_zone()); phase.Run(); }
431 void MarkLive(HValue* ref, HValue* instr, ZoneList<HValue*>* worklist); 433 void MarkLive(HValue* ref, HValue* instr, ZoneList<HValue*>* worklist);
432 void MarkLiveInstructions(); 434 void MarkLiveInstructions();
433 void RemoveDeadInstructions(); 435 void RemoveDeadInstructions();
434 void MarkAsDeoptimizingRecursively(HBasicBlock* block); 436 void MarkAsDeoptimizingRecursively(HBasicBlock* block);
435 void NullifyUnreachableInstructions(); 437 void NullifyUnreachableInstructions();
436 void InsertTypeConversions(HInstruction* instr); 438 void InsertTypeConversions(HInstruction* instr);
437 void PropagateMinusZeroChecks(HValue* value, BitVector* visited); 439 void PropagateMinusZeroChecks(HValue* value, BitVector* visited);
438 void RecursivelyMarkPhiDeoptimizeOnUndefined(HPhi* phi); 440 void RecursivelyMarkPhiDeoptimizeOnUndefined(HPhi* phi);
439 void InsertRepresentationChangeForUse(HValue* value, 441 void InsertRepresentationChangeForUse(HValue* value,
440 HValue* use_value, 442 HValue* use_value,
(...skipping 1610 matching lines...) Expand 10 before | Expand all | Expand 10 after
2051 EmbeddedVector<char, 64> filename_; 2053 EmbeddedVector<char, 64> filename_;
2052 HeapStringAllocator string_allocator_; 2054 HeapStringAllocator string_allocator_;
2053 StringStream trace_; 2055 StringStream trace_;
2054 int indent_; 2056 int indent_;
2055 }; 2057 };
2056 2058
2057 2059
2058 } } // namespace v8::internal 2060 } } // namespace v8::internal
2059 2061
2060 #endif // V8_HYDROGEN_H_ 2062 #endif // V8_HYDROGEN_H_
OLDNEW
« no previous file with comments | « no previous file | src/hydrogen.cc » ('j') | src/hydrogen-environment-liveness.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698