[PATCH] D93088: [OpenMPIRBuilder] Various changes required for tileLoops.

Michael Kruse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 10 22:43:20 PST 2020


Meinersbur created this revision.
Meinersbur added reviewers: jdoerfert, AMDChirag, anchu-rajendran, kiranchandramohan, SouraVX, ftynse, kiranktp, fghanim.
Herald added subscribers: guansong, hiraditya, yaxunl.
Meinersbur requested review of this revision.
Herald added a subscriber: sstefan1.
Herald added a project: LLVM.

Extract some changes not directly related to tileLoops out of D92974 <https://reviews.llvm.org/D92974>:

- Refactor `createLoopSkeleton` out of `createCanonicalLoop`.
- Introduce `ComputeIP` parameter to the `createCanonicalLoop` overload inserts instructions to compute the trip count. Specifying the location is necessary to make these instructions appear before the outermost loop of a loop nest that is tiled.
- Introduce `Name` parameter to `createCanonicalLoop`. This can help better understanding the origin of values of basic blocks with many loops. The default value is "loop" instead of "for" which could be confused with the "for directive" (aka worksharing-loop) and does not apply to Fortran.
- Remove `CanonicalLoopInfo::eraseFromParent` which is currently unused and untested and was added in anticipation to be used by `tileLoops`. `eraseFromParent` has shown to be insufficient when more than a single loop is involved and is replaced by `removeUnusedBlocksFromParent` in D92974 <https://reviews.llvm.org/D92974>.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D93088

Files:
  llvm/include/llvm/Frontend/OpenMP/OMPIRBuilder.h
  llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D93088.311112.patch
Type: text/x-patch
Size: 12426 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201211/951b8f09/attachment.bin>


More information about the llvm-commits mailing list