[PATCH] D101374: [LV] Consider Loop Unroll Hints When Making Interleave Decisions

Bardia Mahjour via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 28 14:04:52 PDT 2021


bmahjour marked an inline comment as done.
bmahjour added a comment.

> It was based that function on what Clang generates with the primary intention to generate "your pragma has been ignored" warnings. llvm.loop.unroll.runtime.disable would still allow full unrolling, so it does not fit directly into an enable/disable scheme. Maybe we'd need separate hasFullUnrollTransformation and hasPartialUnrollTransformation functions. Patch welcome.

I see. We should also update the documentation to be clear about the semantics of `llvm.loop.unroll.runtime.disable`, I think.



================
Comment at: llvm/include/llvm/Transforms/Vectorize/LoopVectorizationLegality.h:117
+      return Interleave.Value;
+    if (llvm::hasUnrollTransformation(TheLoop) & TM_Disable)
+      return 1;
----------------
Meinersbur wrote:
> Could you add a comment about what the intention of this is?
> Suggestion:
> ```
> // If interleaving is not explicitly set, assume that if we do not want unrolling, we also don't want any interleaving.
> ```
done.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D101374



More information about the llvm-commits mailing list