[PATCH] D96517: [AMDGPU] Optimize SGPR to scratch spilling

Sebastian Neubauer via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 11 08:33:44 PST 2021


sebastian-ne created this revision.
sebastian-ne added reviewers: arsenm, rampitec, foad, critson, madhur13490, piotr.
Herald added subscribers: kerbowa, hiraditya, t-tye, tpr, dstuttard, yaxunl, nhaehnle, jvesely, kzhuravl, qcolombet.
sebastian-ne requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.

Refactor and optimize spilling SGPRs to scratch. Remove unnecessary
EXEC copies, search a free VGPR with the RegScavenger and save inactive
lanes only if one is found.
Some parts of saving and restoring SGPRs are commoned up in
SGPRSpillBuilder.

Follow-up to D96336 <https://reviews.llvm.org/D96336>.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D96517

Files:
  llvm/lib/Target/AMDGPU/SIRegisterInfo.cpp
  llvm/lib/Target/AMDGPU/SIRegisterInfo.h
  llvm/test/CodeGen/AMDGPU/frame-setup-without-sgpr-to-vgpr-spills.ll
  llvm/test/CodeGen/AMDGPU/partial-sgpr-to-vgpr-spills.ll
  llvm/test/CodeGen/AMDGPU/sgpr-spill.mir
  llvm/test/CodeGen/AMDGPU/si-spill-sgpr-stack.ll
  llvm/test/CodeGen/AMDGPU/spill-special-sgpr.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D96517.323034.patch
Type: text/x-patch
Size: 204323 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210211/9e99e97b/attachment-0001.bin>


More information about the llvm-commits mailing list