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

Side by Side Diff: src/hydrogen.h

Issue 130613003: Eliminatable CheckMaps replaced with if(true) or if(false). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Review notes applied, rev.2 Created 6 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | src/hydrogen.cc » ('j') | src/hydrogen.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 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 bool IsStartBlock() const { return block_id() == 0; } 107 bool IsStartBlock() const { return block_id() == 0; }
108 void PostProcessLoopHeader(IterationStatement* stmt); 108 void PostProcessLoopHeader(IterationStatement* stmt);
109 109
110 bool IsFinished() const { return end_ != NULL; } 110 bool IsFinished() const { return end_ != NULL; }
111 void AddPhi(HPhi* phi); 111 void AddPhi(HPhi* phi);
112 void RemovePhi(HPhi* phi); 112 void RemovePhi(HPhi* phi);
113 void AddInstruction(HInstruction* instr, int position); 113 void AddInstruction(HInstruction* instr, int position);
114 bool Dominates(HBasicBlock* other) const; 114 bool Dominates(HBasicBlock* other) const;
115 int LoopNestingDepth() const; 115 int LoopNestingDepth() const;
116 116
117 void ReplaceControlWithGotoSuccessor(int succ);
118
117 void SetInitialEnvironment(HEnvironment* env); 119 void SetInitialEnvironment(HEnvironment* env);
118 void ClearEnvironment() { 120 void ClearEnvironment() {
119 ASSERT(IsFinished()); 121 ASSERT(IsFinished());
120 ASSERT(end()->SuccessorCount() == 0); 122 ASSERT(end()->SuccessorCount() == 0);
121 last_environment_ = NULL; 123 last_environment_ = NULL;
122 } 124 }
123 bool HasEnvironment() const { return last_environment_ != NULL; } 125 bool HasEnvironment() const { return last_environment_ != NULL; }
124 void UpdateEnvironment(HEnvironment* env); 126 void UpdateEnvironment(HEnvironment* env);
125 HBasicBlock* parent_loop_header() const { return parent_loop_header_; } 127 HBasicBlock* parent_loop_header() const { return parent_loop_header_; }
126 128
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 Goto(block, position, NULL, false); 195 Goto(block, position, NULL, false);
194 } 196 }
195 197
196 // Add the inlined function exit sequence, adding an HLeaveInlined 198 // Add the inlined function exit sequence, adding an HLeaveInlined
197 // instruction and updating the bailout environment. 199 // instruction and updating the bailout environment.
198 void AddLeaveInlined(HValue* return_value, 200 void AddLeaveInlined(HValue* return_value,
199 FunctionState* state, 201 FunctionState* state,
200 int position); 202 int position);
201 203
202 private: 204 private:
205 void MarkSuccEdgeUnreachable(int succ);
203 void RegisterPredecessor(HBasicBlock* pred); 206 void RegisterPredecessor(HBasicBlock* pred);
204 void AddDominatedBlock(HBasicBlock* block); 207 void AddDominatedBlock(HBasicBlock* block);
205 208
206 int block_id_; 209 int block_id_;
207 HGraph* graph_; 210 HGraph* graph_;
208 ZoneList<HPhi*> phis_; 211 ZoneList<HPhi*> phis_;
209 HInstruction* first_; 212 HInstruction* first_;
210 HInstruction* last_; 213 HInstruction* last_;
211 HControlInstruction* end_; 214 HControlInstruction* end_;
212 HLoopInformation* loop_information_; 215 HLoopInformation* loop_information_;
(...skipping 2477 matching lines...) Expand 10 before | Expand all | Expand 10 after
2690 } 2693 }
2691 2694
2692 private: 2695 private:
2693 HGraphBuilder* builder_; 2696 HGraphBuilder* builder_;
2694 }; 2697 };
2695 2698
2696 2699
2697 } } // namespace v8::internal 2700 } } // namespace v8::internal
2698 2701
2699 #endif // V8_HYDROGEN_H_ 2702 #endif // V8_HYDROGEN_H_
OLDNEW
« no previous file with comments | « no previous file | src/hydrogen.cc » ('j') | src/hydrogen.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698