File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -120,7 +120,7 @@ class LoopBlocksDFS {
120
120
Loop *getLoop () const { return L; }
121
121
122
122
// / Traverse the loop blocks and store the DFS result.
123
- void perform (LoopInfo *LI);
123
+ void perform (const LoopInfo *LI);
124
124
125
125
// / Return true if postorder numbers are assigned to all loop blocks.
126
126
bool isComplete () const { return PostBlocks.size () == L->getNumBlocks (); }
@@ -177,7 +177,7 @@ class LoopBlocksRPO {
177
177
LoopBlocksRPO (Loop *Container) : DFS(Container) {}
178
178
179
179
// / Traverse the loop blocks and store the DFS result.
180
- void perform (LoopInfo *LI) {
180
+ void perform (const LoopInfo *LI) {
181
181
DFS.perform (LI);
182
182
}
183
183
@@ -204,10 +204,10 @@ class LoopBlocksTraversal {
204
204
205
205
private:
206
206
LoopBlocksDFS &DFS;
207
- LoopInfo *LI;
207
+ const LoopInfo *LI;
208
208
209
209
public:
210
- LoopBlocksTraversal (LoopBlocksDFS &Storage, LoopInfo *LInfo) :
210
+ LoopBlocksTraversal (LoopBlocksDFS &Storage, const LoopInfo *LInfo) :
211
211
DFS (Storage), LI(LInfo) {}
212
212
213
213
// / Postorder traversal over the graph. This only needs to be done once.
Original file line number Diff line number Diff line change @@ -1218,7 +1218,7 @@ PreservedAnalyses LoopVerifierPass::run(Function &F,
1218
1218
// / Traverse the loop blocks and store the DFS result.
1219
1219
// / Useful for clients that just want the final DFS result and don't need to
1220
1220
// / visit blocks during the initial traversal.
1221
- void LoopBlocksDFS::perform (LoopInfo *LI) {
1221
+ void LoopBlocksDFS::perform (const LoopInfo *LI) {
1222
1222
LoopBlocksTraversal Traversal (*this , LI);
1223
1223
for (LoopBlocksTraversal::POTIterator POI = Traversal.begin (),
1224
1224
POE = Traversal.end ();
You can’t perform that action at this time.
0 commit comments