[PATCH] D28767: Do not verify Dominator tree if it has no roots
Serge Pavlov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 24 05:59:08 PST 2017
sepavloff added a comment.
> IIRC, when I wrote the patch to add the verifyDomTree function here it was taken verbatim from the IR level dominator tree verifier. Therefore, it might be a good idea to make a similar change to the IR-level verifier.
This change fixes 11 test fails observer when llvm was build with LLVM_ENABLE_EXPENSIVE_CHECKS turned on. None of them occurs in IR but some time ago there were such fails. So added the respective check.
================
Comment at: lib/CodeGen/MachineDominators.cpp:147
+ if (getRoots().empty())
+ // If no roots found in the dominator tree, the pass that builds it is
+ // likely to be skipped.
----------------
mcrosier wrote:
> I'd probably drop this comment in favor of the title of this revision, "Do not verify Dominator tree if it has no root."
Rephrased the comment.
https://reviews.llvm.org/D28767
More information about the llvm-commits
mailing list