[llvm] [AMDGPU][true16] extract 16bit for scratch_load_ubyte_st when spilling (PR #203589)

Joe Nash via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 12 10:56:02 PDT 2026


================
@@ -1939,7 +1939,8 @@ void SIRegisterInfo::buildSpillLoadStore(
     }
 
     Register FinalValueReg = ValueReg;
-    if (LoadStoreOp == AMDGPU::SCRATCH_LOAD_USHORT_SADDR) {
+    if (LoadStoreOp == AMDGPU::SCRATCH_LOAD_USHORT_SADDR ||
+        LoadStoreOp == AMDGPU::SCRATCH_LOAD_USHORT_ST) {
       // If we are loading 16-bit value with SRAMECC endabled we need a temp
----------------
Sisyph wrote:

Need to handle SV form as well? it looks like getFlatScratchInstSTfromSS can return it.

https://github.com/llvm/llvm-project/pull/203589


More information about the llvm-commits mailing list