[PATCH] D123651: [AMDGPU][NFC] Organize code around reserving VGPR32 for AGPR copy.

Mahesha S via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 13 18:30:21 PDT 2022


hsmhsm marked an inline comment as done.
hsmhsm added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/SIRegisterInfo.cpp:1557
+        TmpIntermediateVGPR = FuncInfo->getVGPRForAGPRCopy();
+        assert(MF->getRegInfo().isReserved(TmpIntermediateVGPR));
       }
----------------
rampitec wrote:
> There is already assert inside getVGPRForAGPRCopy.
The assert inside getVGPRForAGPRCopy() is to assert that some valid VGPR (only in case of gfx908) is **identified**, which may or may not yet reserved (by calling getReservedRegs()).

On the other hand, the assert here assert that the identified valid VGPR is also **reserved**.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D123651



More information about the llvm-commits mailing list