]> granicus.if.org Git - llvm/commit
Do not verify MachimeDominatorTree if it is not calculated
authorSerge Pavlov <sepavloff@gmail.com>
Thu, 2 Mar 2017 12:00:10 +0000 (12:00 +0000)
committerSerge Pavlov <sepavloff@gmail.com>
Thu, 2 Mar 2017 12:00:10 +0000 (12:00 +0000)
commite9106e2cd2ac3b1954254b8c0984c155e9463399
treeafcbc8ee0c29c526061b8dfe5f72a49e3e0f3175
parent76fd0de16f82214114b2760eeb766af984e27ff0
Do not verify MachimeDominatorTree if it is not calculated

If dominator tree is not calculated or is invalidated, set corresponding
pointer in the pass state to nullptr. Such pointer value will indicate
that operations with dominator tree are not allowed. In particular, it
allows to skip verification for such pass state. The dominator tree is
not calculated if the machine dominator pass was skipped, it occures in
the case of entities with linkage available_externally.

The change fixes some test fails observed when expensive checks
are enabled.

Differential Revision: https://reviews.llvm.org/D29280

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@296742 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/MachineDominators.h
lib/CodeGen/MachineDominators.cpp
test/CodeGen/Generic/externally_available.ll