[PATCH] D123865: [LoopPeel] Allow partial unrolling for profile-based peeling

David Li via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 15 14:00:06 PDT 2022


davidxl added a comment.

In D123865#3454607 <https://reviews.llvm.org/D123865#3454607>, @ikudrin wrote:

> Our test was for AArch64, so there should be no effects like loop alignment, if I understand you right.

Alignment related uArch quirks  is much less likely to happen, but is still possible.

> I couldn't find a benchmark to test the change against, so I prepared an artificial one based on `LLVM test suite/SingleSource/Benchmarks/Adobe-C++/loop-unroll.cpp`. I saw the performance gain >10%-30% depending on the iterations count (on x86_64). But I understand that that test is probably biased, so if you recommend some commonly recognized public benchmark that might be suitable for >the case, I would try it. As for a more deep analysis, could you share some examples so I can grab some ideas from them?

You want to try programs with large instruction working set and are built with PGO. Lacking those, at least SPEC06 or SPEC17

As regard the analysis, you can try perf events like cycles, retired instructions,  retired taken branches, branch-mispredictions etc to help you understand the improvement better.


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

https://reviews.llvm.org/D123865



More information about the llvm-commits mailing list