[llvm] [AMDGPU] Try to reuse in v_cndmask register with constant from compare. (PR #131146)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 13 09:23:56 PDT 2025
arsenm wrote:
> I tried to detect these cases and revert the optimisation in amdgpu-codegenprepare, but realised that in some cases (e.g. when immediate can be encoded into instruction, depending on the target and the constant) it can increase registers usage (as well as instructions count).
That would be too late, plenty of compare and select patterns appear during legalization
https://github.com/llvm/llvm-project/pull/131146
More information about the llvm-commits
mailing list