diff options
author | Adam Nemet <anemet@apple.com> | 2015-05-06 08:18:41 +0000 |
---|---|---|
committer | Adam Nemet <anemet@apple.com> | 2015-05-06 08:18:41 +0000 |
commit | e340f851a34e1df081d1999e95a56331e8555968 (patch) | |
tree | 321e9102e122a07c489161f661680b61ea2867d7 /llvm/lib/IR/Dominators.cpp | |
parent | f2453a01fb13b337aec87eaa058ba2eb576a9773 (diff) | |
download | bcm5719-llvm-e340f851a34e1df081d1999e95a56331e8555968.tar.gz bcm5719-llvm-e340f851a34e1df081d1999e95a56331e8555968.zip |
[DomTree] verifyDomTree to unconditionally perform DT verification
I folded the check for the flag -verify-dom-info into the only caller
where I think it is supposed to be checked: verifyAnalysis. (The idea
of the flag is to enable this expensive verification in
verifyPreservedAnalysis.)
I'm assuming that when manually scheduling the verification pass
with -passes=verify<domtree>, we do want to perform the verification.
llvm-svn: 236575
Diffstat (limited to 'llvm/lib/IR/Dominators.cpp')
-rw-r--r-- | llvm/lib/IR/Dominators.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/IR/Dominators.cpp b/llvm/lib/IR/Dominators.cpp index 9b6ff1eb136..e3258895ea5 100644 --- a/llvm/lib/IR/Dominators.cpp +++ b/llvm/lib/IR/Dominators.cpp @@ -282,9 +282,6 @@ bool DominatorTree::isReachableFromEntry(const Use &U) const { } void DominatorTree::verifyDomTree() const { - if (!VerifyDomInfo) - return; - Function &F = *getRoot()->getParent(); DominatorTree OtherDT; @@ -350,7 +347,10 @@ bool DominatorTreeWrapperPass::runOnFunction(Function &F) { return false; } -void DominatorTreeWrapperPass::verifyAnalysis() const { DT.verifyDomTree(); } +void DominatorTreeWrapperPass::verifyAnalysis() const { + if (VerifyDomInfo) + DT.verifyDomTree(); +} void DominatorTreeWrapperPass::print(raw_ostream &OS, const Module *) const { DT.print(OS); |