[PATCH] D148824: AMDGPU: Define sub-class of SGPR_64 for tail call return

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 26 08:50:05 PDT 2023


arsenm added a comment.

In D148824#4299117 <https://reviews.llvm.org/D148824#4299117>, @sebastian-ne wrote:

> In D148824#4299075 <https://reviews.llvm.org/D148824#4299075>, @arsenm wrote:
>
>> Stepping back for a moment, why does amdgpu_gfx use a different set of callee saved registers? It shouldn't really have different needs
>
> Right, it does not have different needs.
>
> Both, compute and graphics, pass user data in SGPR and want to preserve them through function calls.
> In compute, all of this is handled through reserved registers in the AMDGPU backend. In graphics, everything is more variable, so we handle user-data in the frontend and add it as `inreg` arguments to all functions.

We should start respecting inreg for regular functions. It's just ignored right now. We just wouldn't make use of it as-is.


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

https://reviews.llvm.org/D148824



More information about the llvm-commits mailing list