]> granicus.if.org Git - llvm/commit
[AMDGPU] Select AGPR in PHI operand legalization
authorStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Mon, 21 Oct 2019 19:25:27 +0000 (19:25 +0000)
committerStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Mon, 21 Oct 2019 19:25:27 +0000 (19:25 +0000)
commit6e6c5e79c99dc0eca108cd4bcaa4e31b9c64ea35
tree33b3712ec7c13b12111df5ebffd301c7aa7b4357
parentb1407138d45ba368aefd73f33ecb25f09432531a
[AMDGPU] Select AGPR in PHI operand legalization

If a PHI defines AGPR legalize its operands to AGPR.
At the moment we can get an AGPR PHI with VGPR operands.
I am not aware of any problems as it seems to be handled
gracefully in RA, but this is not right anyway.

It also slightly decreases VGPR pressure in some cases
because we do not have to a copy via VGPR.

Differential Revision: https://reviews.llvm.org/D69206

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@375446 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AMDGPU/SIInstrInfo.cpp
test/CodeGen/AMDGPU/mfma-loop.ll