[llvm] [LoopInterchange] Constrain number of load/stores in a loop (PR #118973)

Sjoerd Meijer via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 16 03:36:49 PST 2025


================
@@ -109,7 +115,16 @@ static bool populateDependencyMatrix(CharMatrix &DepMatrix, unsigned Level,
 
   LLVM_DEBUG(dbgs() << "Found " << MemInstr.size()
                     << " Loads and Stores to analyze\n");
-
+  if (MemInstr.size() > MaxMemInstrCount) {
+    LLVM_DEBUG(dbgs() << "The transform doesn't support more than "
+                      << MaxMemInstrCount << " load stores in a loop\n");
----------------
sjoerdmeijer wrote:

Nit: "load stores" -> loads/stores

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


More information about the llvm-commits mailing list