[llvm] [LoopInterchange] Bail out when finding a dependency with all `*` elements (PR #149049)

Ryotaro Kasuga via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 25 02:05:06 PDT 2025


================
@@ -260,6 +260,18 @@ static bool populateDependencyMatrix(CharMatrix &DepMatrix, unsigned Level,
           Dep.push_back('I');
         }
 
+        // If there is a direction vector with all entries being '*', we cannot
+        // prove the legality of the interchange for arbitrary pairs of loops.
+        // Exit early in this case to save compile time.
+        if (all_of(Dep, [](char C) { return C == '*'; })) {
----------------
kasuga-fj wrote:

fixed, thanks

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


More information about the llvm-commits mailing list