[PATCH] D112690: MachineDominators: Define MachineDomTree type alias
Sameer Sahasrabuddhe via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 28 10:01:14 PDT 2021
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGb437aaa672e8: MachineDominators: Define MachineDomTree type alias (authored by nhaehnle, committed by sameerds).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D112690/new/
https://reviews.llvm.org/D112690
Files:
llvm/include/llvm/CodeGen/MachineDominators.h
llvm/lib/CodeGen/MachineDominators.cpp
Index: llvm/lib/CodeGen/MachineDominators.cpp
===================================================================
--- llvm/lib/CodeGen/MachineDominators.cpp
+++ llvm/lib/CodeGen/MachineDominators.cpp
@@ -73,7 +73,7 @@
void MachineDominatorTree::verifyAnalysis() const {
if (DT && VerifyMachineDomInfo)
- if (!DT->verify(DomTreeT::VerificationLevel::Basic)) {
+ if (!DT->verify(MachineDomTree::VerificationLevel::Basic)) {
errs() << "MachineDominatorTree verification failed\n";
abort();
}
Index: llvm/include/llvm/CodeGen/MachineDominators.h
===================================================================
--- llvm/include/llvm/CodeGen/MachineDominators.h
+++ llvm/include/llvm/CodeGen/MachineDominators.h
@@ -36,6 +36,7 @@
extern template class DominatorTreeBase<MachineBasicBlock, false>; // DomTree
extern template class DominatorTreeBase<MachineBasicBlock, true>; // PostDomTree
+using MachineDomTree = DomTreeBase<MachineBasicBlock>;
using MachineDomTreeNode = DomTreeNodeBase<MachineBasicBlock>;
//===-------------------------------------
@@ -43,8 +44,6 @@
/// compute a normal dominator tree.
///
class MachineDominatorTree : public MachineFunctionPass {
- using DomTreeT = DomTreeBase<MachineBasicBlock>;
-
/// Helper structure used to hold all the basic blocks
/// involved in the split of a critical edge.
struct CriticalEdge {
@@ -67,7 +66,7 @@
mutable SmallSet<MachineBasicBlock *, 32> NewBBs;
/// The DominatorTreeBase that is used to compute a normal dominator tree.
- std::unique_ptr<DomTreeT> DT;
+ std::unique_ptr<MachineDomTree> DT;
/// Apply all the recorded critical edges to the DT.
/// This updates the underlying DT information in a way that uses
@@ -84,8 +83,9 @@
calculate(MF);
}
- DomTreeT &getBase() {
- if (!DT) DT.reset(new DomTreeT());
+ MachineDomTree &getBase() {
+ if (!DT)
+ DT.reset(new MachineDomTree());
applySplitCriticalEdges();
return *DT;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D112690.383074.patch
Type: text/x-patch
Size: 1992 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211028/8df51f9f/attachment.bin>
More information about the llvm-commits
mailing list