[llvm] r372924 - [LICM] Don't verify domtree/loopinfo unless EXPENSIVE_CHECKS is enabled.
Eli Friedman via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 25 15:35:47 PDT 2019
Author: efriedma
Date: Wed Sep 25 15:35:47 2019
New Revision: 372924
URL: http://llvm.org/viewvc/llvm-project?rev=372924&view=rev
Log:
[LICM] Don't verify domtree/loopinfo unless EXPENSIVE_CHECKS is enabled.
For large functions, verifying the whole function after each loop takes
non-linear time.
Differential Revision: https://reviews.llvm.org/D67571
Modified:
llvm/trunk/lib/Transforms/Scalar/LICM.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/LICM.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LICM.cpp?rev=372924&r1=372923&r2=372924&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/LICM.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/LICM.cpp Wed Sep 25 15:35:47 2019
@@ -963,7 +963,7 @@ bool llvm::hoistRegion(DomTreeNode *N, A
// Now that we've finished hoisting make sure that LI and DT are still
// valid.
-#ifndef NDEBUG
+#ifdef EXPENSIVE_CHECKS
if (Changed) {
assert(DT->verify(DominatorTree::VerificationLevel::Fast) &&
"Dominator tree verification failed");
More information about the llvm-commits
mailing list