[PATCH] D73129: [LoopUnrollAndJam] Correctly update LoopInfo when unroll and jam more than 2-levels loop nests.

Whitney Tsang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 22 14:31:33 PST 2020


Whitney updated this revision to Diff 239701.
Whitney marked 2 inline comments as done.
Whitney added a comment.

Change the test case back to A[i][j][k] = 0 as I agreed that it is the minimal meaningful body for a three level loop nests. 
Also use different upper bound for each loop as suggested by Johannes.

As for what to put for the checks. We could
(1) one check for the induction variable (original patch)
(2) only control flow (suggested by @dmgreen)
(3) all checks (suggested by @jdoerfert)
(4) all checks except the loop body
I don't mind any of them, as long as we know the loop nest is unroll and jammed, and LoopInfo verified, which all 4 suggestion satisfy, 
I will wait to see if we can get to a conclusion before doing further changes. Currently is (3).


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D73129

Files:
  llvm/lib/Transforms/Utils/LoopUnrollAndJam.cpp
  llvm/test/Transforms/LoopUnrollAndJam/loopnest.ll
  llvm/test/Transforms/LoopUnrollAndJam/unroll-and-jam.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D73129.239701.patch
Type: text/x-patch
Size: 16395 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200122/f257ad26/attachment.bin>


More information about the llvm-commits mailing list