Home | History | Annotate | Download | only in LoopUnroll
      1 ; PR28103
      2 ; Bail out if the two successors are not the header
      3 ; and another bb outside of the loop. This case is not
      4 ; properly handled by LoopUnroll, currently.
      5 
      6 ; RUN: opt -loop-unroll -verify-dom-info %s
      7 ; REQUIRES: asserts
      8 
      9 define void @tinkywinky(i1 %patatino) {
     10 entry:
     11   br label %header1
     12 header1:
     13   %indvars.iv = phi i64 [ 1, %body2 ], [ 0, %entry ]
     14   %exitcond = icmp ne i64 %indvars.iv, 1
     15   br i1 %exitcond, label %body1, label %exit
     16 body1:
     17   br i1 %patatino, label %body2, label %sink
     18 body2:
     19   br i1 %patatino, label %header1, label %body3
     20 body3:
     21   br label %sink
     22 sink:
     23   br label %body2
     24 exit:
     25   ret void
     26 }
     27