Skip to content

Commit c1c32e2

Browse files
committed
Add test for ctpop with poison arg
1 parent 3efa461 commit c1c32e2

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

llvm/test/Transforms/InstSimplify/fold-intrinsics.ll

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,11 @@ define void @powi_i16(float %V, ptr%P) {
4444

4545
ret void
4646
}
47+
48+
define i32 @test_ctpop_poison(i32 %a) {
49+
; CHECK-LABEL: @test_ctpop_poison(
50+
; CHECK-NEXT: ret i32 0
51+
;
52+
%res = tail call i32 @llvm.ctpop.i32(i32 poison)
53+
ret i32 %res
54+
}

0 commit comments

Comments
 (0)