[PATCH] D156105: [AMDGPU][True16] Support generating differently-sized register transfers.

Ivan Kosarev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 24 11:44:02 PDT 2023


kosarev added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/SIInstrInfo.cpp:740-744
+        MCRegister &RegToFix = (Size == 16) ? DestReg : SrcReg;
+        MCRegister Super = RI.get32BitRegister(RegToFix);
+        assert(RI.getSubReg(Super, AMDGPU::lo16) == RegToFix ||
+               RI.getSubReg(Super, AMDGPU::hi16) == RegToFix);
+        RegToFix = Super;
----------------
arsenm wrote:
> Is this actually reachable? I forget how exactly we ended up with this partial 16-bit register thing
I'm going to try to understand more about what's going on here, but maybe @Joe_Nash already knows the answer as he was working on that bit.


================
Comment at: llvm/lib/Target/AMDGPU/SIInstrInfo.cpp:741
+        MCRegister &RegToFix = (Size == 16) ? DestReg : SrcReg;
+        MCRegister Super = RI.get32BitRegister(RegToFix);
+        assert(RI.getSubReg(Super, AMDGPU::lo16) == RegToFix ||
----------------
rampitec wrote:
> Are these tabs?
Nope, just re-indendting with proper spaces.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D156105



More information about the llvm-commits mailing list