forked from OSchip/llvm-project
Remove braces around single-statement block and rangify outer loop.
This is a follow-up to r213474. llvm-svn: 213475
This commit is contained in:
parent
d11beffef4
commit
6d5cc8d656
|
@ -528,12 +528,9 @@ void BranchProbabilityInfo::print(raw_ostream &OS, const Module *) const {
|
||||||
// We print the probabilities from the last function the analysis ran over,
|
// We print the probabilities from the last function the analysis ran over,
|
||||||
// or the function it is currently running over.
|
// or the function it is currently running over.
|
||||||
assert(LastF && "Cannot print prior to running over a function");
|
assert(LastF && "Cannot print prior to running over a function");
|
||||||
for (Function::const_iterator BI = LastF->begin(), BE = LastF->end();
|
for (const BasicBlock &BB : *LastF)
|
||||||
BI != BE; ++BI) {
|
for (const BasicBlock *Succ : successors(&BB))
|
||||||
for (const BasicBlock *Succ : successors(BI)) {
|
printEdgeProbability(OS << " ", &BB, Succ);
|
||||||
printEdgeProbability(OS << " ", BI, Succ);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32_t BranchProbabilityInfo::getSumForBlock(const BasicBlock *BB) const {
|
uint32_t BranchProbabilityInfo::getSumForBlock(const BasicBlock *BB) const {
|
||||||
|
|
Loading…
Reference in New Issue