Skip to content

Commit aa34d1e

Browse files
committed
implement feedback
1 parent c6f3b88 commit aa34d1e

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

llvm/test/Verifier/AMDGPU/intrinsic-amdgpu-init-exec-from-input.ll

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
; RUN: not llvm-as -o /dev/null 2>&1 %s | FileCheck %s
1+
; RUN: not llvm-as -disable-output 2>&1 %s | FileCheck %s
22

33
; Function Attrs: convergent nocallback nofree nounwind willreturn
44
declare void @llvm.amdgcn.init.exec.from.input(i32, i32 immarg) #0
@@ -17,3 +17,11 @@ define amdgpu_ps void @init_exec_from_input_fail_not_inreg(i32 inreg %a, i32 %b)
1717
call void @llvm.amdgcn.init.exec.from.input(i32 %b, i32 0)
1818
ret void
1919
}
20+
21+
; CHECK: only inreg arguments to the parent function are valid as inputs to this intrinsic
22+
; CHECK-NEXT: call void @llvm.amdgcn.init.exec.from.input(i32 %c, i32 0)
23+
define amdgpu_ps void @init_exec_from_input_fail_constant(i32 inreg %a, i32 %b) {
24+
%c = add i32 %a, %b
25+
call void @llvm.amdgcn.init.exec.from.input(i32 %c, i32 0)
26+
ret void
27+
}

0 commit comments

Comments
 (0)