[llvm] 1eb5588 - AMDGPU: Replace i16 undefs with poison in tests (#131084)

via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 13 04:52:53 PDT 2025


Author: Matt Arsenault
Date: 2025-03-13T18:52:49+07:00
New Revision: 1eb5588457c39a924902971b7d883e319a499c17

URL: https://github.com/llvm/llvm-project/commit/1eb5588457c39a924902971b7d883e319a499c17
DIFF: https://github.com/llvm/llvm-project/commit/1eb5588457c39a924902971b7d883e319a499c17.diff

LOG: AMDGPU: Replace i16 undefs with poison in tests (#131084)

Added: 
    

Modified: 
    llvm/test/CodeGen/AMDGPU/inline-constraints.ll
    llvm/test/CodeGen/AMDGPU/shrink-add-sub-constant.ll

Removed: 
    


################################################################################
diff  --git a/llvm/test/CodeGen/AMDGPU/inline-constraints.ll b/llvm/test/CodeGen/AMDGPU/inline-constraints.ll
index 2888fd77a9b53..3aa6f3a43d2ee 100644
--- a/llvm/test/CodeGen/AMDGPU/inline-constraints.ll
+++ b/llvm/test/CodeGen/AMDGPU/inline-constraints.ll
@@ -295,7 +295,7 @@ define i32 @inline_A_constraint_V1() {
 
 ; NOGCN: error: invalid operand for inline asm constraint 'A'
 define i32 @inline_A_constraint_V2() {
-  %v0 = tail call i32 asm "v_mov_b32 $0, $1", "=v,A"(<2 x i16> <i16 -4, i16 undef>)
+  %v0 = tail call i32 asm "v_mov_b32 $0, $1", "=v,A"(<2 x i16> <i16 -4, i16 poison>)
   ret i32 %v0
 }
 
@@ -456,7 +456,7 @@ define i32 @inline_I_constraint_V1() {
 
 ; NOGCN: error: invalid operand for inline asm constraint 'I'
 define i32 @inline_I_constraint_V2() {
-  %v0 = tail call i32 asm "v_mov_b32 $0, $1", "=v,I"(<2 x i16> <i16 -4, i16 undef>)
+  %v0 = tail call i32 asm "v_mov_b32 $0, $1", "=v,I"(<2 x i16> <i16 -4, i16 poison>)
   ret i32 %v0
 }
 
@@ -1160,7 +1160,7 @@ define i32 @inline_DA_constraint_V1() {
 
 ; NOGCN: error: invalid operand for inline asm constraint 'DA'
 define i32 @inline_DA_constraint_V2() {
-  %v0 = tail call i32 asm "v_mov_b32 $0, $1", "=v,^DA"(<2 x i16> <i16 -4, i16 undef>)
+  %v0 = tail call i32 asm "v_mov_b32 $0, $1", "=v,^DA"(<2 x i16> <i16 -4, i16 poison>)
   ret i32 %v0
 }
 

diff  --git a/llvm/test/CodeGen/AMDGPU/shrink-add-sub-constant.ll b/llvm/test/CodeGen/AMDGPU/shrink-add-sub-constant.ll
index fe45d7d0284bb..21aa40d69998e 100644
--- a/llvm/test/CodeGen/AMDGPU/shrink-add-sub-constant.ll
+++ b/llvm/test/CodeGen/AMDGPU/shrink-add-sub-constant.ll
@@ -4249,7 +4249,7 @@ define amdgpu_kernel void @v_test_v2i16_x_add_undef_neg32(ptr addrspace(1) %out,
   %gep = getelementptr inbounds <2 x i16>, ptr addrspace(1) %in, i64 %tid.ext
   %gep.out = getelementptr inbounds <2 x i16>, ptr addrspace(1) %out, i64 %tid.ext
   %x = load <2 x i16>, ptr addrspace(1) %gep
-  %result = add <2 x i16> %x, <i16 undef, i16 -32>
+  %result = add <2 x i16> %x, <i16 poison, i16 -32>
   store <2 x i16> %result, ptr addrspace(1) %gep.out
   ret void
 }
@@ -4403,7 +4403,7 @@ define amdgpu_kernel void @v_test_v2i16_x_add_neg32_undef(ptr addrspace(1) %out,
   %gep = getelementptr inbounds <2 x i16>, ptr addrspace(1) %in, i64 %tid.ext
   %gep.out = getelementptr inbounds <2 x i16>, ptr addrspace(1) %out, i64 %tid.ext
   %x = load <2 x i16>, ptr addrspace(1) %gep
-  %result = add <2 x i16> %x, <i16 -32, i16 undef>
+  %result = add <2 x i16> %x, <i16 -32, i16 poison>
   store <2 x i16> %result, ptr addrspace(1) %gep.out
   ret void
 }


        


More information about the llvm-commits mailing list