[PATCH] D93715: AMDGPU: Don't fold AGPR copy pairs that need a temp VGPR

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 22 09:51:48 PST 2020


arsenm created this revision.
arsenm added reviewers: rampitec, kerbowa.
Herald added subscribers: hiraditya, t-tye, tpr, dstuttard, yaxunl, nhaehnle, jvesely, kzhuravl.
arsenm requested review of this revision.
Herald added a subscriber: wdng.
Herald added a project: LLVM.

Do not fold SGPR->VGPR->AGPR copies, or AGPR->VGPR->AGPR copies. We
need to introduce a temporary VGPR. It's better if this this temp
register is explicitly visible to the register allocator, rather than
relying on the register scavenger later. A future change will
introduce the temporary VGPRs, and this combine would undo that.


https://reviews.llvm.org/D93715

Files:
  llvm/lib/Target/AMDGPU/SIFoldOperands.cpp
  llvm/lib/Target/AMDGPU/SIRegisterInfo.h
  llvm/test/CodeGen/AMDGPU/fold-operands-agpr-copies.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D93715.313376.patch
Type: text/x-patch
Size: 9705 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201222/d2b6a051/attachment.bin>


More information about the llvm-commits mailing list