[all-commits] [llvm/llvm-project] 46a13a: [AArch64] Runtime-unroll small multi-exit loops on...

Florian Hahn via All-commits all-commits at lists.llvm.org
Thu Feb 27 06:43:08 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 46a13a5b174b031b399606f92ca049cac8aa12a0
      https://github.com/llvm/llvm-project/commit/46a13a5b174b031b399606f92ca049cac8aa12a0
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2025-02-27 (Thu, 27 Feb 2025)

  Changed paths:
    M llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
    M llvm/test/Transforms/LoopUnroll/AArch64/apple-unrolling-multi-exit.ll

  Log Message:
  -----------
  [AArch64] Runtime-unroll small multi-exit loops on Apple Silicon. (#124751)

Extend unrolling preferences to allow more aggressive unrolling of
search loops with 2 exits, building on the TTI hook added in

https://github.com/llvm/llvm-project/commit/ad9da92cf6f735747ef04fd56937e1d76819e503.

In combination with
https://github.com/llvm/llvm-project/commit/eac23a5b971362cda3c646e018b9f26d0bc1ff3a
this enables unrolling loops like
std::find, which can improve performance significantly (+15% end-to-end
on a workload that makes heavy use of std::find). It increase the total
number of unrolled loops by ~2.5% across a very large corpus of
workloads.

For SPEC2017, +1.6% more loops are unrolled and the following workloads
increase in size (`__text`):

      workload             base                patch  
    500.perlbench_r   1682884.00         1694104.00  0.7%
    523.xalancbmk_r   3001716.00          3003832.00  0.1%

PR: https://github.com/llvm/llvm-project/pull/124751



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list