[llvm] AMDGPU: Simplify foldImmediate with register class based checks (PR #154682)

Joe Nash via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 21 06:48:49 PDT 2025


================
@@ -128,7 +128,7 @@ body:             |
 
     ; GCN-LABEL: name: fold_sreg_64_sub0_to_vgpr_32
     ; GCN: [[S_MOV_B:%[0-9]+]]:sreg_64 = S_MOV_B64_IMM_PSEUDO 1311768467750121200
-    ; GCN-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 -1412567312, implicit $exec
+    ; GCN-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 2882399984, implicit $exec
----------------
Sisyph wrote:

I think this is the immediate rendering change from zero extended to sign extended. Why is it ok for the transformation to choose which one to use?

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


More information about the llvm-commits mailing list