55 lines · plain
1; RUN: llc < %s -mtriple=x86_64-- | FileCheck %s2 3%"class.std::bitset" = type { [8 x i8] }4 5define zeroext i1 @_Z3fooPjmS_mRSt6bitsetILm32EE(ptr nocapture %a, i64 %asize, ptr nocapture %b, i64 %bsize, ptr %bits) nounwind readonly ssp noredzone {6entry:7 br label %for.cond8 9for.cond: ; preds = %for.inc, %entry10 %0 = phi i32 [ 0, %entry ], [ %inc, %for.inc ]11 %conv = zext i32 %0 to i6412 %cmp = icmp eq i64 %conv, %bsize13 br i1 %cmp, label %return, label %for.body14 15for.body: ; preds = %for.cond16 %arrayidx = getelementptr inbounds i32, ptr %b, i64 %conv17 %tmp5 = load i32, ptr %arrayidx, align 418 %conv6 = zext i32 %tmp5 to i6419 %rem.i.i.i.i = and i64 %conv6, 6320 %tmp3.i = load i64, ptr %bits, align 821 %shl.i.i = shl i64 1, %rem.i.i.i.i22 %and.i = and i64 %shl.i.i, %tmp3.i23 %cmp.i = icmp eq i64 %and.i, 024 br i1 %cmp.i, label %for.inc, label %return25 26for.inc: ; preds = %for.body27 %inc = add i32 %0, 128 br label %for.cond29 30return: ; preds = %for.body, %for.cond31; CHECK-NOT: and32 %retval.0 = phi i1 [ true, %for.body ], [ false, %for.cond ]33 ret i1 %retval.034}35 36; This test case caused an assertion failure; see PR9324.37define void @func_37(i1 %arg) noreturn nounwind ssp {38entry:39 br i1 %arg, label %lbl_919, label %entry.for.inc_crit_edge40 41entry.for.inc_crit_edge: ; preds = %entry42 br label %for.inc43 44lbl_919: ; preds = %for.cond7.preheader, %entry45 br label %for.cond7.preheader46 47for.cond7.preheader: ; preds = %for.inc, %lbl_91948 %storemerge.ph = phi i8 [ 0, %lbl_919 ], [ %add, %for.inc ]49 br i1 %arg, label %for.inc, label %lbl_91950 51for.inc: ; preds = %for.cond7.preheader, %entry.for.inc_crit_edge52 %add = add i8 undef, 153 br label %for.cond7.preheader54}55