diff options
author | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2014-02-04 19:19:07 +0000 |
---|---|---|
committer | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2014-02-04 19:19:07 +0000 |
commit | 8e661efc00f2138412286bdb4662e9e7995ee23f (patch) | |
tree | bf2d93b5d60ae34ab44c1448af7021cc466a7dd2 /llvm/lib/Analysis/IPA/GlobalsModRef.cpp | |
parent | d554a8eb91116cf055f36e3ffe34cb262a110fd5 (diff) | |
download | bcm5719-llvm-8e661efc00f2138412286bdb4662e9e7995ee23f.tar.gz bcm5719-llvm-8e661efc00f2138412286bdb4662e9e7995ee23f.zip |
cleanup: scc_iterator consumers should use isAtEnd
No functional change. Updated loops from:
for (I = scc_begin(), E = scc_end(); I != E; ++I)
to:
for (I = scc_begin(); !I.isAtEnd(); ++I)
for teh win.
llvm-svn: 200789
Diffstat (limited to 'llvm/lib/Analysis/IPA/GlobalsModRef.cpp')
-rw-r--r-- | llvm/lib/Analysis/IPA/GlobalsModRef.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/Analysis/IPA/GlobalsModRef.cpp b/llvm/lib/Analysis/IPA/GlobalsModRef.cpp index e0723026de7..2a8b96da069 100644 --- a/llvm/lib/Analysis/IPA/GlobalsModRef.cpp +++ b/llvm/lib/Analysis/IPA/GlobalsModRef.cpp @@ -367,8 +367,7 @@ bool GlobalsModRef::AnalyzeIndirectGlobalMemory(GlobalValue *GV) { void GlobalsModRef::AnalyzeCallGraph(CallGraph &CG, Module &M) { // We do a bottom-up SCC traversal of the call graph. In other words, we // visit all callees before callers (leaf-first). - for (scc_iterator<CallGraph*> I = scc_begin(&CG), E = scc_end(&CG); I != E; - ++I) { + for (scc_iterator<CallGraph*> I = scc_begin(&CG); !I.isAtEnd(); ++I) { std::vector<CallGraphNode *> &SCC = *I; assert(!SCC.empty() && "SCC with no functions?"); |