aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp
diff options
context:
space:
mode:
authorPhilip Reames <listmail@philipreames.com>2021-09-02 16:27:45 -0700
committerPhilip Reames <listmail@philipreames.com>2021-09-02 16:28:46 -0700
commit45c672e20d40be1f6dfc68ff0ee5347c91833d7c (patch)
tree06a03646750833be7bab3746196ec4fa2a05af7a /llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp
parentfdac5adee6c9e9699e05f7b32b1a62816b9fed7d (diff)
downloadllvm-45c672e20d40be1f6dfc68ff0ee5347c91833d7c.zip
llvm-45c672e20d40be1f6dfc68ff0ee5347c91833d7c.tar.gz
llvm-45c672e20d40be1f6dfc68ff0ee5347c91833d7c.tar.bz2
[runtimeunroll] Under EXPENSIVE_CHECKS, validate loop info
Requested in review comment on D108476
Diffstat (limited to 'llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp')
-rw-r--r--llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp b/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp
index 86aa43c..105c628f 100644
--- a/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp
+++ b/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp
@@ -939,10 +939,12 @@ bool llvm::UnrollRuntimeLoopRemainder(
// of its parent loops, so the Scalar Evolution pass needs to be run again.
SE->forgetTopmostLoop(L);
- // Verify that the Dom Tree is correct.
+ // Verify that the Dom Tree and Loop Info are correct.
#if defined(EXPENSIVE_CHECKS) && !defined(NDEBUG)
- if (DT)
+ if (DT) {
assert(DT->verify(DominatorTree::VerificationLevel::Full));
+ LI->verify(*DT);
+ }
#endif
// For unroll factor 2 remainder loop will have 1 iteration.