[PATCH] D112644: [AMDGPU] Fix global isel for kernels using agprs on gfx90a

Stanislav Mekhanoshin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 27 12:48:23 PDT 2021


rampitec added a comment.

In D112644#3091209 <https://reviews.llvm.org/D112644#3091209>, @arsenm wrote:

> In D112644#3091088 <https://reviews.llvm.org/D112644#3091088>, @rampitec wrote:
>
>> In D112644#3091054 <https://reviews.llvm.org/D112644#3091054>, @arsenm wrote:
>>
>>> How was this breaking?
>>
>> LLVM ERROR: no registers from class available to allocate
>>
>> What happens `usesAGPRs()` does not see any agprs used and then the whole register budget is allocated to vgprs.
>
> Wouldn't it work correctly after later getReservedRegs calls? I don't think we should be calling this before finalizeIsel?

It does work correctly with a later call from `freezeReservedRegs()`. The first call though comes from `MachineVerifier::visitMachineFunctionBefore()`.


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

https://reviews.llvm.org/D112644



More information about the llvm-commits mailing list