[PATCH] D106126: [LoopUnroll] Double thresholds instead of increasing to pragma-unroll-threshold for llvm.loop.unroll.enable

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 15 22:04:14 PDT 2021


MaskRay created this revision.
MaskRay added reviewers: nikic, reames, zsrkmyn.
Herald added subscribers: zzheng, hiraditya.
MaskRay requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Fix PR51084: `#pragma unroll` aggressively increases `UP.Threshold` from (150
for -O2 and 300 for -O3) to 16384. This is usually undesired. Just double the
thresholds.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D106126

Files:
  llvm/lib/Transforms/Scalar/LoopUnrollPass.cpp
  llvm/test/Transforms/LoopUnroll/unroll-pragmas.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D106126.359216.patch
Type: text/x-patch
Size: 4547 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210716/f96ac482/attachment.bin>


More information about the llvm-commits mailing list