[llvm] 36f3254 - [SCEV] Don't verify dispositions of invalid loops
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 19 06:07:55 PDT 2022
Author: Nikita Popov
Date: 2022-09-19T15:07:44+02:00
New Revision: 36f325413ec27819f8e4c1cd22d5f5e8a6a43000
URL: https://github.com/llvm/llvm-project/commit/36f325413ec27819f8e4c1cd22d5f5e8a6a43000
DIFF: https://github.com/llvm/llvm-project/commit/36f325413ec27819f8e4c1cd22d5f5e8a6a43000.diff
LOG: [SCEV] Don't verify dispositions of invalid loops
This should fix the expensive checks build. Ideally we would not
have invalid loops in LoopDispositions.
Added:
Modified:
llvm/lib/Analysis/ScalarEvolution.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Analysis/ScalarEvolution.cpp b/llvm/lib/Analysis/ScalarEvolution.cpp
index 31204a41df5c..966bb3594433 100644
--- a/llvm/lib/Analysis/ScalarEvolution.cpp
+++ b/llvm/lib/Analysis/ScalarEvolution.cpp
@@ -13976,6 +13976,9 @@ void ScalarEvolution::verify() const {
for (auto &V : Values) {
auto CachedDisposition = V.getInt();
const auto *Loop = V.getPointer();
+ // TODO: Make sure LoopDispositions contains no invalid loops.
+ if (!ValidLoops.contains(Loop))
+ continue;
const auto RecomputedDisposition = SE2.getLoopDisposition(S, Loop);
if (CachedDisposition != RecomputedDisposition) {
dbgs() << "Cached disposition of " << *S << " for loop " << *Loop
More information about the llvm-commits
mailing list