Home | History | Annotate | Download | only in ScalarEvolution
      1 ; RUN: opt < %s -indvars -adce -simplifycfg -S | FileCheck %s
      2 ; PR1598
      3 
      4 ; CHECK: icmp s
      5 
      6 define i32 @f(i32 %a, i32 %b, i32 %x, i32 %y) {
      7 entry:
      8 	%tmp3 = icmp eq i32 %a, %b		; <i1> [#uses=1]
      9 	br i1 %tmp3, label %return, label %bb
     10 
     11 bb:		; preds = %bb, %entry
     12 	%x_addr.0 = phi i32 [ %tmp6, %bb ], [ %x, %entry ]		; <i32> [#uses=1]
     13 	%tmp6 = add i32 %x_addr.0, 1		; <i32> [#uses=3]
     14 	%tmp9 = icmp slt i32 %tmp6, %y		; <i1> [#uses=1]
     15 	br i1 %tmp9, label %bb, label %return
     16 
     17 return:		; preds = %bb, %entry
     18 	%x_addr.1 = phi i32 [ %x, %entry ], [ %tmp6, %bb ]		; <i32> [#uses=1]
     19 	ret i32 %x_addr.1
     20 }
     21