[llvm] [AArch64][GISel] Skip SME call-attr checks on non-SME targets (PR #190135)
Cullen Rhodes via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 7 04:59:46 PDT 2026
c-rhodes wrote:
> > Is there any way to add a test for this?
>
> not that i can think of unless I'm missing something? This just avoids the expensive fallback checks for non-SME targets since it would never fallback (and still doesn't of course), so nothing is really changing
I tried changing the `aarch64_pstate_sm_compatible`/ `aarch64_za_state_agnostic` tests in https://github.com/llvm/llvm-project/blob/main/llvm/test/CodeGen/AArch64/sme-disable-gisel-fisel.ll to move the features to function attrs and only enable +sve but it breaks the tests (check lines change). Not really sure what's going on there tbh but it seemed non-trivial and I also noticed the attr checking shows in the profile too so is a bit expensive:
<img width="1198" height="553" alt="image" src="https://github.com/user-attachments/assets/3d064607-8cdc-4c5d-8b66-553988dab454" />
so I've changed it to also do the checks if SVE is enabled which should cover the case you mentioned.
https://github.com/llvm/llvm-project/pull/190135
More information about the llvm-commits
mailing list