[PATCH] D120386: [LoopInterchange] Try to achieve the most optimal access pattern after interchange

Michael Kruse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 4 18:05:16 PDT 2022


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

LGTM



================
Comment at: llvm/lib/Transforms/Scalar/LoopInterchange.cpp:430-431
   bool run(LoopNest &LN) {
-    const auto &LoopList = LN.getLoops();
+    auto LoopList =
+        SmallVector<Loop *, 8>(LN.getLoops().begin(), LN.getLoops().end());
     for (unsigned I = 1; I < LoopList.size(); ++I)
----------------
One less call of a copy ctor.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D120386

STAMPS
actor(@Meinersbur) application(Differential) author(@congzhe) herald(H114) herald(H140) herald(H225) herald(H237) herald(H343) herald(H428) herald(H479) herald(H497) herald(H576) herald(H615) herald(H678) herald(H864) monogram(D120386) object-type(DREV) phid(PHID-DREV-5ahfjh7pir6ujidrmshl) reviewer(#loopoptwg) reviewer(@bmahjour) reviewer(@fhahn) reviewer(@Meinersbur) reviewer(@Whitney) revision-repository(rG) revision-status(accepted) subscriber(@hiraditya) subscriber(@llvm-commits) tag(#all) tag(#llvm) via(web)



More information about the llvm-commits mailing list