[PATCH] D134930: [LoopInterchange] Do not interchange when a reduction phi in all subloops of the outer loop is not recognizable

Michael Kruse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 18 23:08:39 PDT 2022


Meinersbur accepted this revision.
Meinersbur added a comment.
This revision is now accepted and ready to land.

LGTM. Thank you.

The additional check make sense.



================
Comment at: llvm/lib/Transforms/Scalar/LoopInterchange.cpp:854
+  // if a phi node at a certain nesting level cannot be properly recognized.
+  auto *CurLevelLoop = OuterLoop;
+  while (!CurLevelLoop->getSubLoops().empty()) {
----------------
[nit] LLVM does not use Almost-Always-Auto,


================
Comment at: llvm/test/Transforms/LoopInterchange/multilevel-partial-reduction.ll:1
+; RUN: opt < %s -basic-aa -loop-interchange -cache-line-size=64 -pass-remarks-missed='loop-interchange' -pass-remarks-output=%t -S \
+; RUN:     -verify-dom-info -verify-loop-info -verify-loop-lcssa
----------------
The the pass `-basic-aa` doesn't seem to exist anymore, might be a recent change.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D134930/new/

https://reviews.llvm.org/D134930



More information about the llvm-commits mailing list