[llvm] [DA] Simplify runtime predicate collection and extend to all dependence tests (PR #157523)

Ryotaro Kasuga via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 9 02:07:42 PDT 2025


================
@@ -4036,6 +4049,12 @@ DependenceInfo::depends(Instruction *Src, Instruction *Dst,
       return nullptr;
   }
 
+  // If runtime assumptions were added but not allowed, return confused
+  // dependence.
+  if (!UnderRuntimeAssumptions && !Assumptions.empty())
+    return std::make_unique<Dependence>(Src, Dst, getNonRedundantAssumptions());
----------------
kasuga-fj wrote:

I think using assert like `UnderRuntimeAssumptions || Assumptions.empty()` would be better here. We should not add any runtime assumptions if it's not allowed.

https://github.com/llvm/llvm-project/pull/157523


More information about the llvm-commits mailing list