[PATCH] D20115: Loop unroller: set thresholds for optsize and minsize functions to zero

Hans Wennborg via llvm-commits llvm-commits at lists.llvm.org
Tue May 10 09:57:28 PDT 2016


hans created this revision.
hans added reviewers: mamai, rnk.
hans added a subscriber: llvm-commits.
Herald added a subscriber: mzolotukhin.

Before r268509, Clang would disable the loop unroll pass when optimizing for size. That commit enabled it, to be able to support unroll pragmas in -Os builds. However, this regressed binary size in one of Chromium's DLLs with ~100 KB.

This restores the original behaviour of no unrolling at -Os, but doing it in LLVM instead of Clang makes more sense, and also allows the pragmas to keep working.

http://reviews.llvm.org/D20115

Files:
  lib/Transforms/Scalar/LoopUnrollPass.cpp
  test/Transforms/LoopUnroll/PowerPC/a2-unrolling.ll
  test/Transforms/LoopUnroll/PowerPC/p7-unrolling.ll
  test/Transforms/LoopUnroll/partial-unroll-optsize.ll
  test/Transforms/LoopUnroll/unroll-opt-attribute.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D20115.56741.patch
Type: text/x-patch
Size: 8007 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160510/dea2c0e9/attachment.bin>


More information about the llvm-commits mailing list