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

Side by Side Diff: src/compiler/loop-analysis.h

Issue 1578723002: [turbofan] Build s/NULL/nullptr/g and CHECK(x != nullptr) to CHECK_NOT_NULL(x). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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
« no previous file with comments | « src/compiler/linkage.cc ('k') | src/compiler/machine-operator-reducer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_COMPILER_LOOP_ANALYSIS_H_ 5 #ifndef V8_COMPILER_LOOP_ANALYSIS_H_
6 #define V8_COMPILER_LOOP_ANALYSIS_H_ 6 #define V8_COMPILER_LOOP_ANALYSIS_H_
7 7
8 #include "src/base/iterator.h" 8 #include "src/base/iterator.h"
9 #include "src/compiler/graph.h" 9 #include "src/compiler/graph.h"
10 #include "src/compiler/node.h" 10 #include "src/compiler/node.h"
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 &loop_nodes_[0] + loop->body_end_); 106 &loop_nodes_[0] + loop->body_end_);
107 } 107 }
108 108
109 // Return the node that represents the control, i.e. the loop node itself. 109 // Return the node that represents the control, i.e. the loop node itself.
110 Node* GetLoopControl(Loop* loop) { 110 Node* GetLoopControl(Loop* loop) {
111 // TODO(turbofan): make the loop control node always first? 111 // TODO(turbofan): make the loop control node always first?
112 for (Node* node : HeaderNodes(loop)) { 112 for (Node* node : HeaderNodes(loop)) {
113 if (node->opcode() == IrOpcode::kLoop) return node; 113 if (node->opcode() == IrOpcode::kLoop) return node;
114 } 114 }
115 UNREACHABLE(); 115 UNREACHABLE();
116 return NULL; 116 return nullptr;
117 } 117 }
118 118
119 private: 119 private:
120 friend class LoopFinderImpl; 120 friend class LoopFinderImpl;
121 121
122 Loop* NewLoop() { 122 Loop* NewLoop() {
123 all_loops_.push_back(Loop(zone_)); 123 all_loops_.push_back(Loop(zone_));
124 Loop* result = &all_loops_.back(); 124 Loop* result = &all_loops_.back();
125 return result; 125 return result;
126 } 126 }
(...skipping 20 matching lines...) Expand all
147 // Build a loop tree for the entire graph. 147 // Build a loop tree for the entire graph.
148 static LoopTree* BuildLoopTree(Graph* graph, Zone* temp_zone); 148 static LoopTree* BuildLoopTree(Graph* graph, Zone* temp_zone);
149 }; 149 };
150 150
151 151
152 } // namespace compiler 152 } // namespace compiler
153 } // namespace internal 153 } // namespace internal
154 } // namespace v8 154 } // namespace v8
155 155
156 #endif // V8_COMPILER_LOOP_ANALYSIS_H_ 156 #endif // V8_COMPILER_LOOP_ANALYSIS_H_
OLDNEW
« no previous file with comments | « src/compiler/linkage.cc ('k') | src/compiler/machine-operator-reducer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698