[llvm] r296569 - clang-format GenericDomTreeConstruction.h, since the current formatting makes it look like their is a bug in the loop indentation, and there is not
Daniel Berlin via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 28 18:50:47 PST 2017
Author: dannyb
Date: Tue Feb 28 20:50:46 2017
New Revision: 296569
URL: http://llvm.org/viewvc/llvm-project?rev=296569&view=rev
Log:
clang-format GenericDomTreeConstruction.h, since the current formatting makes it look like their is a bug in the loop indentation, and there is not
Modified:
llvm/trunk/include/llvm/Support/GenericDomTreeConstruction.h
Modified: llvm/trunk/include/llvm/Support/GenericDomTreeConstruction.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/GenericDomTreeConstruction.h?rev=296569&r1=296568&r2=296569&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/GenericDomTreeConstruction.h (original)
+++ llvm/trunk/include/llvm/Support/GenericDomTreeConstruction.h Tue Feb 28 20:50:46 2017
@@ -171,7 +171,7 @@ void Calculate(DominatorTreeBaseByGraphT
}
}
// Accounting for the virtual exit, see if we had any unreachable nodes
- if (Total + 1 != N ) {
+ if (Total + 1 != N) {
// Make another DFS pass over all other nodes to find the unreachable
// blocks, and find the furthest paths we'll be able to make.
// Note that this looks N^2, but it's really 2N worst case, if every node
@@ -194,21 +194,20 @@ void Calculate(DominatorTreeBaseByGraphT
ConnectToExitBlock.insert(FurthestAway);
N = ReverseDFSPass<GraphT>(DT, FurthestAway, N);
}
- // Finally, now everything should be visited, and anything with parent
- // ==
- // 0 should be connected to virtual exit.
- for (auto *Node : ConnectToExitBlock) {
- auto FindResult = DT.Info.find(Node);
- assert(FindResult != DT.Info.end() &&
- "Everything should have been visited by now");
- if (FindResult->second.Parent == 0) {
- FindResult->second.Parent = 1;
- DT.addRoot(Node);
- }
+ // Finally, now everything should be visited, and anything with parent ==
+ // 0 should be connected to virtual exit.
+ for (auto *Node : ConnectToExitBlock) {
+ auto FindResult = DT.Info.find(Node);
+ assert(FindResult != DT.Info.end() &&
+ "Everything should have been visited by now");
+ if (FindResult->second.Parent == 0) {
+ FindResult->second.Parent = 1;
+ DT.addRoot(Node);
}
}
- } else {
- N = DFSPass<GraphT>(DT, GraphTraits<FuncT *>::getEntryNode(&F), N);
+ }
+ } else {
+ N = DFSPass<GraphT>(DT, GraphTraits<FuncT *>::getEntryNode(&F), N);
}
// When naively implemented, the Lengauer-Tarjan algorithm requires a separate
More information about the llvm-commits
mailing list