[PATCH] D61055: [LoopSimplifyCFG] Suppress expensive DomTree verification in LoopSimplifyCFG

Yevgeny Rouban via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 23 21:39:32 PDT 2019


yrouban created this revision.
yrouban added reviewers: reames, mkazantsev.
Herald added a subscriber: hiraditya.
Herald added a project: LLVM.

This patch makes verification level lower for builds with inexpensive checks.


Repository:
  rL LLVM

https://reviews.llvm.org/D61055

Files:
  llvm/lib/Transforms/Scalar/LoopSimplifyCFG.cpp


Index: llvm/lib/Transforms/Scalar/LoopSimplifyCFG.cpp
===================================================================
--- llvm/lib/Transforms/Scalar/LoopSimplifyCFG.cpp
+++ llvm/lib/Transforms/Scalar/LoopSimplifyCFG.cpp
@@ -598,7 +598,13 @@
 
 #ifndef NDEBUG
     // Make sure that we have preserved all data structures after the transform.
-    assert(DT.verify() && "DT broken after transform!");
+#if defined(EXPENSIVE_CHECKS)
+    assert(DT.verify(DominatorTree::VerificationLevel::Full) &&
+           "DT broken after transform!");
+#else
+    assert(DT.verify(DominatorTree::VerificationLevel::Basic) &&
+           "DT broken after transform!");
+#endif
     assert(DT.isReachableFromEntry(Header));
     LI.verify(DT);
 #endif


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61055.196382.patch
Type: text/x-patch
Size: 740 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190424/472c2a82/attachment.bin>


More information about the llvm-commits mailing list