51 lines · plain
1; RUN: llc < %s -O2 -mtriple=i386-pc-linux-gnu -relocation-model=pic | FileCheck %s2; PR9237: Assertion in VirtRegRewriter.cpp, ResurrectConfirmedKill3; `KillOps[*SR] == KillOp && "invalid subreg kill flags"'4 5%t = type { i32 }6 7define i32 @foo(ptr %s) nounwind {8entry:9 br label %if.then73510 11if.then735:12 %call747 = call i32 undef(ptr %s, ptr null, ptr undef, i32 128, ptr undef, i32 516) nounwind13 br i1 undef, label %if.then751, label %if.then75814 15if.then751:16 unreachable17 18if.then758:19 %add761 = add i32 %call747, 420 %add763 = add i32 %add761, %call74721 %add.ptr768 = getelementptr inbounds [516 x i8], ptr null, i32 0, i32 %add76122 br i1 undef, label %cond.false783, label %cond.true77123 24cond.true771:25 %call782 = call ptr @__memmove_chk(ptr %add.ptr768, ptr undef, i32 %call747, i32 undef)26 br label %cond.end79127 28; CHECK: calll __memmove_chk29cond.false783:30 %call.i1035 = call ptr @__memmove_chk(ptr %add.ptr768, ptr undef, i32 %call747, i32 undef) nounwind31 br label %cond.end79132 33cond.end791:34 %conv801 = trunc i32 %call747 to i835 %add.ptr822.sum = add i32 %call747, 336 %arrayidx833 = getelementptr inbounds [516 x i8], ptr null, i32 0, i32 %add.ptr822.sum37 store i8 %conv801, ptr %arrayidx833, align 138 %cmp841 = icmp eq ptr undef, null39 br i1 %cmp841, label %if.end849, label %if.then84340 41if.then843:42 unreachable43 44if.end849:45 %call921 = call i32 undef(ptr %s, ptr undef, ptr undef, i32 %add763) nounwind46 unreachable47 48}49 50declare ptr @__memmove_chk(ptr, ptr, i32, i32) nounwind51