1 ; RUN: opt -loop-rotate -disable-output %s
2 ; RUN: opt -passes=loop-rotate -disable-output %s
4 ; Make sure we don't crash on this test.
5 define void @foo(i32* %arg) {
7 %tmp = load i32, i32* %arg, align 4
10 bb1: ; preds = %bb7, %bb
11 %tmp2 = phi i32 [ %tmp, %bb ], [ 1, %bb7 ]
12 %tmp3 = sub i32 0, %tmp2
13 %tmp4 = icmp ult i32 0, %tmp3
14 %tmp5 = freeze i1 %tmp4
15 br i1 %tmp5, label %bb7, label %bb6
21 %tmp8 = getelementptr inbounds i8, i8* undef, i64 8