[llvm] [llvm-exegesis] Implement the loop repetition mode for AArch64 (PR #154751)

Aiden Grossman via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 21 11:34:31 PDT 2025


boomanaiden154 wrote:

> One semi-related question to this: do you know if --min-instructions is supposed to work with -repetition-mode=loop? I would like to increase the loop body, but --min-instructions only seem to have an effect when in duplicate mode. Option middle-half-loop seem to achieve what I want, it gives me more accurate numbers for the couple of examples I've tried, but was wondering if I could control this sort of behaviour myself with min-instructions.

I haven't touched the code in a while, but I'm pretty sure `--min-instructions` in loop mode changes the number of loop iterations rather than the number of instructions in the loop. `middle-half-loop` will do two runs, one with double the number of loop iterations of the other and then subtract them to subtract out setup costs.

I believe you're looking for the `--loop-body-size` flag.

https://github.com/llvm/llvm-project/pull/154751


More information about the llvm-commits mailing list