Home | History | Annotate | Download | only in ScalarEvolution
      1 ; RUN: opt < %s -analyze -scalar-evolution | FileCheck %s
      2 
      3 ; PR13228
      4 define void @f() nounwind uwtable readnone {
      5 entry:
      6   br label %for.cond
      7 
      8 for.cond:                                         ; preds = %for.cond, %entry
      9   %c.0 = phi i8 [ 1, %entry ], [ 0, %for.cond ]
     10   %i.0 = phi i8 [ 0, %entry ], [ %inc, %for.cond ]
     11   %lnot = icmp eq i8 %i.0, 0
     12   %inc = add i8 %i.0, 1
     13   br i1 %lnot, label %for.cond, label %while.cond
     14 
     15 while.cond:                                       ; preds = %while.body, %for.cond
     16   %b.2 = phi i8 [ %add, %while.body ], [ 0, %for.cond ]
     17   br i1 undef, label %while.end, label %while.body
     18 
     19 while.body:                                       ; preds = %while.cond
     20   %add = add i8 %b.2, %c.0
     21   %tobool7 = icmp eq i8 %add, 0
     22   br i1 %tobool7, label %while.end, label %while.cond
     23 
     24 while.end:                                        ; preds = %while.body, %while.cond
     25   ret void
     26 }
     27 ;CHECK: Loop %while.cond: <multiple exits> Unpredictable backedge-taken count.
     28