Home | History | Annotate | Download | only in LCSSA
      1 ; RUN: opt < %s -lcssa -disable-output -verify-dom-info -verify-loop-info
      2 ; PR977
      3 ; END.
      4 declare i32 @opost_block()
      5 
      6 define void @write_chan() {
      7 entry:
      8 	br i1 false, label %shortcirc_next.0, label %shortcirc_done.0
      9 shortcirc_next.0:		; preds = %entry
     10 	br label %shortcirc_done.0
     11 shortcirc_done.0:		; preds = %shortcirc_next.0, %entry
     12 	br i1 false, label %shortcirc_next.1, label %shortcirc_done.1
     13 shortcirc_next.1:		; preds = %shortcirc_done.0
     14 	br label %shortcirc_done.1
     15 shortcirc_done.1:		; preds = %shortcirc_next.1, %shortcirc_done.0
     16 	br i1 false, label %then.0, label %endif.0
     17 then.0:		; preds = %shortcirc_done.1
     18 	br i1 false, label %then.1, label %endif.1
     19 then.1:		; preds = %then.0
     20 	br label %return
     21 after_ret.0:		; No predecessors!
     22 	br label %endif.1
     23 endif.1:		; preds = %after_ret.0, %then.0
     24 	br label %endif.0
     25 endif.0:		; preds = %endif.1, %shortcirc_done.1
     26 	br label %loopentry.0
     27 loopentry.0:		; preds = %endif.12, %endif.0
     28 	br i1 false, label %then.2, label %endif.2
     29 then.2:		; preds = %loopentry.0
     30 	br label %loopexit.0
     31 dead_block_after_break.0:		; No predecessors!
     32 	br label %endif.2
     33 endif.2:		; preds = %dead_block_after_break.0, %loopentry.0
     34 	br i1 false, label %shortcirc_done.2, label %shortcirc_next.2
     35 shortcirc_next.2:		; preds = %endif.2
     36 	br i1 false, label %shortcirc_next.3, label %shortcirc_done.3
     37 shortcirc_next.3:		; preds = %shortcirc_next.2
     38 	br label %shortcirc_done.3
     39 shortcirc_done.3:		; preds = %shortcirc_next.3, %shortcirc_next.2
     40 	br label %shortcirc_done.2
     41 shortcirc_done.2:		; preds = %shortcirc_done.3, %endif.2
     42 	br i1 false, label %then.3, label %endif.3
     43 then.3:		; preds = %shortcirc_done.2
     44 	br label %loopexit.0
     45 dead_block_after_break.1:		; No predecessors!
     46 	br label %endif.3
     47 endif.3:		; preds = %dead_block_after_break.1, %shortcirc_done.2
     48 	br i1 false, label %shortcirc_next.4, label %shortcirc_done.4
     49 shortcirc_next.4:		; preds = %endif.3
     50 	br label %shortcirc_done.4
     51 shortcirc_done.4:		; preds = %shortcirc_next.4, %endif.3
     52 	br i1 false, label %then.4, label %else
     53 then.4:		; preds = %shortcirc_done.4
     54 	br label %loopentry.1
     55 loopentry.1:		; preds = %endif.8, %then.4
     56 	br i1 false, label %no_exit, label %loopexit.1
     57 no_exit:		; preds = %loopentry.1
     58 	%tmp.94 = call i32 @opost_block( )		; <i32> [#uses=1]
     59 	br i1 false, label %then.5, label %endif.5
     60 then.5:		; preds = %no_exit
     61 	br i1 false, label %then.6, label %endif.6
     62 then.6:		; preds = %then.5
     63 	br label %loopexit.1
     64 dead_block_after_break.2:		; No predecessors!
     65 	br label %endif.6
     66 endif.6:		; preds = %dead_block_after_break.2, %then.5
     67 	br label %break_out
     68 dead_block_after_goto.0:		; No predecessors!
     69 	br label %endif.5
     70 endif.5:		; preds = %dead_block_after_goto.0, %no_exit
     71 	br i1 false, label %then.7, label %endif.7
     72 then.7:		; preds = %endif.5
     73 	br label %loopexit.1
     74 dead_block_after_break.3:		; No predecessors!
     75 	br label %endif.7
     76 endif.7:		; preds = %dead_block_after_break.3, %endif.5
     77 	switch i32 1, label %switchexit [
     78 		 i32 4, label %label.2
     79 		 i32 2, label %label.1
     80 		 i32 1, label %label.0
     81 	]
     82 label.0:		; preds = %endif.7
     83 	br label %switchexit
     84 dead_block_after_break.4:		; No predecessors!
     85 	br label %label.1
     86 label.1:		; preds = %dead_block_after_break.4, %endif.7
     87 	br label %switchexit
     88 dead_block_after_break.5:		; No predecessors!
     89 	br label %label.2
     90 label.2:		; preds = %dead_block_after_break.5, %endif.7
     91 	br label %switchexit
     92 dead_block_after_break.6:		; No predecessors!
     93 	br label %switchexit
     94 switchexit:		; preds = %dead_block_after_break.6, %label.2, %label.1, %label.0, %endif.7
     95 	br i1 false, label %then.8, label %endif.8
     96 then.8:		; preds = %switchexit
     97 	br label %loopexit.1
     98 dead_block_after_break.7:		; No predecessors!
     99 	br label %endif.8
    100 endif.8:		; preds = %dead_block_after_break.7, %switchexit
    101 	br label %loopentry.1
    102 loopexit.1:		; preds = %then.8, %then.7, %then.6, %loopentry.1
    103 	br i1 false, label %then.9, label %endif.9
    104 then.9:		; preds = %loopexit.1
    105 	br label %endif.9
    106 endif.9:		; preds = %then.9, %loopexit.1
    107 	br label %endif.4
    108 else:		; preds = %shortcirc_done.4
    109 	br i1 false, label %then.10, label %endif.10
    110 then.10:		; preds = %else
    111 	br label %break_out
    112 dead_block_after_goto.1:		; No predecessors!
    113 	br label %endif.10
    114 endif.10:		; preds = %dead_block_after_goto.1, %else
    115 	br label %endif.4
    116 endif.4:		; preds = %endif.10, %endif.9
    117 	br i1 false, label %then.11, label %endif.11
    118 then.11:		; preds = %endif.4
    119 	br label %loopexit.0
    120 dead_block_after_break.8:		; No predecessors!
    121 	br label %endif.11
    122 endif.11:		; preds = %dead_block_after_break.8, %endif.4
    123 	br i1 false, label %then.12, label %endif.12
    124 then.12:		; preds = %endif.11
    125 	br label %loopexit.0
    126 dead_block_after_break.9:		; No predecessors!
    127 	br label %endif.12
    128 endif.12:		; preds = %dead_block_after_break.9, %endif.11
    129 	br label %loopentry.0
    130 loopexit.0:		; preds = %then.12, %then.11, %then.3, %then.2
    131 	br label %break_out
    132 break_out:		; preds = %loopexit.0, %then.10, %endif.6
    133 	%retval.3 = phi i32 [ 0, %loopexit.0 ], [ %tmp.94, %endif.6 ], [ 0, %then.10 ]		; <i32> [#uses=0]
    134 	br i1 false, label %cond_true, label %cond_false
    135 cond_true:		; preds = %break_out
    136 	br label %cond_continue
    137 cond_false:		; preds = %break_out
    138 	br label %cond_continue
    139 cond_continue:		; preds = %cond_false, %cond_true
    140 	br label %return
    141 after_ret.1:		; No predecessors!
    142 	br label %return
    143 return:		; preds = %after_ret.1, %cond_continue, %then.1
    144 	ret void
    145 }
    146