We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6ce9531 commit f321614Copy full SHA for f321614
llvm/test/Transforms/InstSimplify/ctpop-pow2.ll
@@ -148,6 +148,19 @@ define <2 x i32> @ctpop_lshr_intmin_vec(<2 x i32> %x) {
148
ret <2 x i32> %cnt
149
}
150
151
+; todo do not remove the assume
152
+define i1 @issue128152(i32 %x) {
153
+; CHECK-LABEL: @issue128152(
154
+; CHECK-NEXT: [[RES:%.*]] = icmp eq i32 [[X:%.*]], 0
155
+; CHECK-NEXT: ret i1 [[RES]]
156
+;
157
+ %ctpop = call i32 @llvm.ctpop.i32(i32 %x)
158
+ %cond = icmp eq i32 %ctpop, 1
159
+ %ext = zext i1 %cond to i8
160
+ call void @llvm.assume(i1 %cond)
161
+ %res = icmp eq i32 %x, 0
162
+ ret i1 %res
163
+}
164
165
define <2 x i32> @ctpop_lshr_intmin_intmin_plus1_vec(<2 x i32> %x) {
166
; CHECK-LABEL: @ctpop_lshr_intmin_intmin_plus1_vec(
0 commit comments