1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
2; RUN: opt < %s -indvars -S -indvars-predicate-loops=0 | FileCheck %s
3
4; Provide legal integer types.
5target datalayout = "n8:16:32:64"
6
7
8@a = common global i32 0, align 4
9@c = common global i32 0, align 4
10@b = common global i32 0, align 4
11
12define void @f() {
13; CHECK-LABEL: @f(
14; CHECK-NEXT:  entry:
15; CHECK-NEXT:    [[TMP0:%.*]] = load i32, i32* @a, align 4
16; CHECK-NEXT:    [[TOBOOL2:%.*]] = icmp eq i32 [[TMP0]], 0
17; CHECK-NEXT:    [[TMP1:%.*]] = load i32, i32* @a, align 4
18; CHECK-NEXT:    [[TOBOOL:%.*]] = icmp eq i32 [[TMP1]], 0
19; CHECK-NEXT:    br label [[FOR_COND2_PREHEADER:%.*]]
20; CHECK:       for.cond2.preheader:
21; CHECK-NEXT:    [[INDVARS_IV:%.*]] = phi i32 [ [[INDVARS_IV_NEXT:%.*]], [[FOR_INC13:%.*]] ], [ -14, [[ENTRY:%.*]] ]
22; CHECK-NEXT:    br i1 [[TOBOOL2]], label [[FOR_INC13]], label [[FOR_BODY3_LR_PH:%.*]]
23; CHECK:       for.body3.lr.ph:
24; CHECK-NEXT:    [[TMP2:%.*]] = add nsw i32 [[INDVARS_IV]], 1
25; CHECK-NEXT:    [[TMP3:%.*]] = icmp ult i32 [[TMP2]], 3
26; CHECK-NEXT:    [[DIV:%.*]] = select i1 [[TMP3]], i32 [[INDVARS_IV]], i32 0
27; CHECK-NEXT:    br i1 false, label [[FOR_BODY3_LR_PH_SPLIT_US:%.*]], label [[FOR_BODY3_LR_PH_FOR_BODY3_LR_PH_SPLIT_CRIT_EDGE:%.*]]
28; CHECK:       for.body3.lr.ph.for.body3.lr.ph.split_crit_edge:
29; CHECK-NEXT:    br label [[FOR_BODY3_LR_PH_SPLIT:%.*]]
30; CHECK:       for.body3.lr.ph.split.us:
31; CHECK-NEXT:    br i1 [[TOBOOL]], label [[FOR_BODY3_LR_PH_SPLIT_US_SPLIT_US:%.*]], label [[FOR_BODY3_LR_PH_SPLIT_US_FOR_BODY3_LR_PH_SPLIT_US_SPLIT_CRIT_EDGE:%.*]]
32; CHECK:       for.body3.lr.ph.split.us.for.body3.lr.ph.split.us.split_crit_edge:
33; CHECK-NEXT:    br label [[FOR_BODY3_LR_PH_SPLIT_US_SPLIT:%.*]]
34; CHECK:       for.body3.lr.ph.split.us.split.us:
35; CHECK-NEXT:    br label [[FOR_BODY3_US_US:%.*]]
36; CHECK:       for.body3.us.us:
37; CHECK-NEXT:    br i1 true, label [[COND_FALSE_US_US:%.*]], label [[COND_END_US_US:%.*]]
38; CHECK:       cond.false.us.us:
39; CHECK-NEXT:    br label [[COND_END_US_US]]
40; CHECK:       cond.end.us.us:
41; CHECK-NEXT:    [[TMP4:%.*]] = load i32, i32* @b, align 4
42; CHECK-NEXT:    [[CMP91_US_US:%.*]] = icmp slt i32 [[TMP4]], 1
43; CHECK-NEXT:    br i1 [[CMP91_US_US]], label [[FOR_INC_LR_PH_US_US:%.*]], label [[FOR_COND2_LOOPEXIT_US_US:%.*]]
44; CHECK:       for.cond2.loopexit.us.us:
45; CHECK-NEXT:    br i1 true, label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_US_LCSSA_US:%.*]], label [[FOR_BODY3_US_US]]
46; CHECK:       for.inc.lr.ph.us.us:
47; CHECK-NEXT:    br label [[FOR_INC_US_US:%.*]]
48; CHECK:       for.cond8.for.cond2.loopexit_crit_edge.us.us:
49; CHECK-NEXT:    store i32 1, i32* @b, align 4
50; CHECK-NEXT:    br label [[FOR_COND2_LOOPEXIT_US_US]]
51; CHECK:       for.inc.us.us:
52; CHECK-NEXT:    [[TMP5:%.*]] = phi i32 [ [[TMP4]], [[FOR_INC_LR_PH_US_US]] ], [ [[INC_US_US:%.*]], [[FOR_INC_US_US]] ]
53; CHECK-NEXT:    [[INC_US_US]] = add nsw i32 [[TMP5]], 1
54; CHECK-NEXT:    [[EXITCOND3:%.*]] = icmp ne i32 [[INC_US_US]], 1
55; CHECK-NEXT:    br i1 [[EXITCOND3]], label [[FOR_INC_US_US]], label [[FOR_COND8_FOR_COND2_LOOPEXIT_CRIT_EDGE_US_US:%.*]]
56; CHECK:       for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa.us:
57; CHECK-NEXT:    br label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US:%.*]]
58; CHECK:       for.body3.lr.ph.split.us.split:
59; CHECK-NEXT:    br label [[FOR_BODY3_US:%.*]]
60; CHECK:       for.body3.us:
61; CHECK-NEXT:    br i1 true, label [[COND_FALSE_US:%.*]], label [[COND_END_US:%.*]]
62; CHECK:       cond.false.us:
63; CHECK-NEXT:    br label [[COND_END_US]]
64; CHECK:       cond.end.us:
65; CHECK-NEXT:    [[TMP6:%.*]] = load i32, i32* @b, align 4
66; CHECK-NEXT:    [[CMP91_US:%.*]] = icmp slt i32 [[TMP6]], 1
67; CHECK-NEXT:    br i1 [[CMP91_US]], label [[FOR_INC_LR_PH_US:%.*]], label [[FOR_COND2_LOOPEXIT_US:%.*]]
68; CHECK:       for.inc.us:
69; CHECK-NEXT:    [[TMP7:%.*]] = phi i32 [ [[TMP6]], [[FOR_INC_LR_PH_US]] ], [ [[INC_US:%.*]], [[FOR_INC_US:%.*]] ]
70; CHECK-NEXT:    [[INC_US]] = add nsw i32 [[TMP7]], 1
71; CHECK-NEXT:    [[EXITCOND2:%.*]] = icmp ne i32 [[INC_US]], 1
72; CHECK-NEXT:    br i1 [[EXITCOND2]], label [[FOR_INC_US]], label [[FOR_COND8_FOR_COND2_LOOPEXIT_CRIT_EDGE_US:%.*]]
73; CHECK:       for.cond2.loopexit.us:
74; CHECK-NEXT:    br i1 false, label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_US_LCSSA:%.*]], label [[FOR_BODY3_US]]
75; CHECK:       for.inc.lr.ph.us:
76; CHECK-NEXT:    br label [[FOR_INC_US]]
77; CHECK:       for.cond8.for.cond2.loopexit_crit_edge.us:
78; CHECK-NEXT:    store i32 1, i32* @b, align 4
79; CHECK-NEXT:    br label [[FOR_COND2_LOOPEXIT_US]]
80; CHECK:       for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa:
81; CHECK-NEXT:    br label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US]]
82; CHECK:       for.cond2.for.inc13_crit_edge.us-lcssa.us:
83; CHECK-NEXT:    [[COND_LCSSA_PH_US:%.*]] = phi i32 [ [[DIV]], [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_US_LCSSA]] ], [ [[DIV]], [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_US_LCSSA_US]] ]
84; CHECK-NEXT:    br label [[FOR_COND2_FOR_INC13_CRIT_EDGE:%.*]]
85; CHECK:       for.body3.lr.ph.split:
86; CHECK-NEXT:    br i1 [[TOBOOL]], label [[FOR_BODY3_LR_PH_SPLIT_SPLIT_US:%.*]], label [[FOR_BODY3_LR_PH_SPLIT_FOR_BODY3_LR_PH_SPLIT_SPLIT_CRIT_EDGE:%.*]]
87; CHECK:       for.body3.lr.ph.split.for.body3.lr.ph.split.split_crit_edge:
88; CHECK-NEXT:    br label [[FOR_BODY3_LR_PH_SPLIT_SPLIT:%.*]]
89; CHECK:       for.body3.lr.ph.split.split.us:
90; CHECK-NEXT:    br label [[FOR_BODY3_US3:%.*]]
91; CHECK:       for.body3.us3:
92; CHECK-NEXT:    br i1 false, label [[COND_FALSE_US4:%.*]], label [[COND_END_US5:%.*]]
93; CHECK:       cond.false.us4:
94; CHECK-NEXT:    br label [[COND_END_US5]]
95; CHECK:       cond.end.us5:
96; CHECK-NEXT:    [[TMP8:%.*]] = load i32, i32* @b, align 4
97; CHECK-NEXT:    [[CMP91_US7:%.*]] = icmp slt i32 [[TMP8]], 1
98; CHECK-NEXT:    br i1 [[CMP91_US7]], label [[FOR_INC_LR_PH_US12:%.*]], label [[FOR_COND2_LOOPEXIT_US11:%.*]]
99; CHECK:       for.inc.us8:
100; CHECK-NEXT:    [[TMP9:%.*]] = phi i32 [ [[TMP8]], [[FOR_INC_LR_PH_US12]] ], [ [[INC_US9:%.*]], [[FOR_INC_US8:%.*]] ]
101; CHECK-NEXT:    [[INC_US9]] = add nsw i32 [[TMP9]], 1
102; CHECK-NEXT:    [[EXITCOND1:%.*]] = icmp ne i32 [[INC_US9]], 1
103; CHECK-NEXT:    br i1 [[EXITCOND1]], label [[FOR_INC_US8]], label [[FOR_COND8_FOR_COND2_LOOPEXIT_CRIT_EDGE_US13:%.*]]
104; CHECK:       for.cond2.loopexit.us11:
105; CHECK-NEXT:    br i1 true, label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_LCSSA_US:%.*]], label [[FOR_BODY3_US3]]
106; CHECK:       for.inc.lr.ph.us12:
107; CHECK-NEXT:    br label [[FOR_INC_US8]]
108; CHECK:       for.cond8.for.cond2.loopexit_crit_edge.us13:
109; CHECK-NEXT:    store i32 1, i32* @b, align 4
110; CHECK-NEXT:    br label [[FOR_COND2_LOOPEXIT_US11]]
111; CHECK:       for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa.us:
112; CHECK-NEXT:    br label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA:%.*]]
113; CHECK:       for.body3.lr.ph.split.split:
114; CHECK-NEXT:    br label [[FOR_BODY3:%.*]]
115; CHECK:       for.cond8.for.cond2.loopexit_crit_edge:
116; CHECK-NEXT:    store i32 1, i32* @b, align 4
117; CHECK-NEXT:    br label [[FOR_COND2_LOOPEXIT:%.*]]
118; CHECK:       for.cond2.loopexit:
119; CHECK-NEXT:    br i1 false, label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_LCSSA:%.*]], label [[FOR_BODY3]]
120; CHECK:       for.body3:
121; CHECK-NEXT:    br i1 false, label [[COND_FALSE:%.*]], label [[COND_END:%.*]]
122; CHECK:       cond.false:
123; CHECK-NEXT:    br label [[COND_END]]
124; CHECK:       cond.end:
125; CHECK-NEXT:    [[TMP10:%.*]] = load i32, i32* @b, align 4
126; CHECK-NEXT:    [[CMP91:%.*]] = icmp slt i32 [[TMP10]], 1
127; CHECK-NEXT:    br i1 [[CMP91]], label [[FOR_INC_LR_PH:%.*]], label [[FOR_COND2_LOOPEXIT]]
128; CHECK:       for.inc.lr.ph:
129; CHECK-NEXT:    br label [[FOR_INC:%.*]]
130; CHECK:       for.inc:
131; CHECK-NEXT:    [[TMP11:%.*]] = phi i32 [ [[TMP10]], [[FOR_INC_LR_PH]] ], [ [[INC:%.*]], [[FOR_INC]] ]
132; CHECK-NEXT:    [[INC]] = add nsw i32 [[TMP11]], 1
133; CHECK-NEXT:    [[EXITCOND:%.*]] = icmp ne i32 [[INC]], 1
134; CHECK-NEXT:    br i1 [[EXITCOND]], label [[FOR_INC]], label [[FOR_COND8_FOR_COND2_LOOPEXIT_CRIT_EDGE:%.*]]
135; CHECK:       for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa:
136; CHECK-NEXT:    br label [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA]]
137; CHECK:       for.cond2.for.inc13_crit_edge.us-lcssa:
138; CHECK-NEXT:    [[COND_LCSSA_PH:%.*]] = phi i32 [ [[INDVARS_IV]], [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_LCSSA]] ], [ [[INDVARS_IV]], [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US_LCSSA_US]] ]
139; CHECK-NEXT:    br label [[FOR_COND2_FOR_INC13_CRIT_EDGE]]
140; CHECK:       for.cond2.for.inc13_crit_edge:
141; CHECK-NEXT:    [[COND_LCSSA:%.*]] = phi i32 [ [[COND_LCSSA_PH]], [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA]] ], [ [[COND_LCSSA_PH_US]], [[FOR_COND2_FOR_INC13_CRIT_EDGE_US_LCSSA_US]] ]
142; CHECK-NEXT:    store i32 [[COND_LCSSA]], i32* @c, align 4
143; CHECK-NEXT:    br label [[FOR_INC13]]
144; CHECK:       for.inc13:
145; CHECK-NEXT:    [[INDVARS_IV_NEXT]] = add nsw i32 [[INDVARS_IV]], 1
146; CHECK-NEXT:    [[EXITCOND4:%.*]] = icmp ne i32 [[INDVARS_IV_NEXT]], 0
147; CHECK-NEXT:    br i1 [[EXITCOND4]], label [[FOR_COND2_PREHEADER]], label [[FOR_END15:%.*]]
148; CHECK:       for.end15:
149; CHECK-NEXT:    ret void
150;
151
152; br i1 {{.*}}, label %[[for_inc13]], label %
153entry:
154  %0 = load i32, i32* @a, align 4
155  %tobool2 = icmp eq i32 %0, 0
156  %1 = load i32, i32* @a, align 4
157  %tobool = icmp eq i32 %1, 0
158  br label %for.cond2.preheader
159
160for.cond2.preheader:                              ; preds = %for.inc13, %entry
161  %storemerge15 = phi i8 [ -14, %entry ], [ %inc14, %for.inc13 ]
162  br i1 %tobool2, label %for.inc13, label %for.body3.lr.ph
163
164for.body3.lr.ph:                                  ; preds = %for.cond2.preheader
165  %tobool5 = icmp eq i8 %storemerge15, 0
166  %conv7 = sext i8 %storemerge15 to i32
167  %2 = add nsw i32 %conv7, 1
168  %3 = icmp ult i32 %2, 3
169  %div = select i1 %3, i32 %conv7, i32 0
170  br i1 %tobool5, label %for.body3.lr.ph.split.us, label %for.body3.lr.ph.for.body3.lr.ph.split_crit_edge
171
172for.body3.lr.ph.for.body3.lr.ph.split_crit_edge:  ; preds = %for.body3.lr.ph
173  br label %for.body3.lr.ph.split
174
175for.body3.lr.ph.split.us:                         ; preds = %for.body3.lr.ph
176  br i1 %tobool, label %for.body3.lr.ph.split.us.split.us, label %for.body3.lr.ph.split.us.for.body3.lr.ph.split.us.split_crit_edge
177
178for.body3.lr.ph.split.us.for.body3.lr.ph.split.us.split_crit_edge: ; preds = %for.body3.lr.ph.split.us
179  br label %for.body3.lr.ph.split.us.split
180
181for.body3.lr.ph.split.us.split.us:                ; preds = %for.body3.lr.ph.split.us
182  br label %for.body3.us.us
183
184for.body3.us.us:                                  ; preds = %for.cond2.loopexit.us.us, %for.body3.lr.ph.split.us.split.us
185  br i1 true, label %cond.false.us.us, label %cond.end.us.us
186
187cond.false.us.us:                                 ; preds = %for.body3.us.us
188  br label %cond.end.us.us
189
190cond.end.us.us:                                   ; preds = %cond.false.us.us, %for.body3.us.us
191  %cond.us.us = phi i32 [ %div, %cond.false.us.us ], [ %conv7, %for.body3.us.us ]
192  %4 = load i32, i32* @b, align 4
193  %cmp91.us.us = icmp slt i32 %4, 1
194  br i1 %cmp91.us.us, label %for.inc.lr.ph.us.us, label %for.cond2.loopexit.us.us
195
196for.cond2.loopexit.us.us:                         ; preds = %for.cond8.for.cond2.loopexit_crit_edge.us.us, %cond.end.us.us
197  br i1 true, label %for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa.us, label %for.body3.us.us
198
199for.inc.lr.ph.us.us:                              ; preds = %cond.end.us.us
200  br label %for.inc.us.us
201
202for.cond8.for.cond2.loopexit_crit_edge.us.us:     ; preds = %for.inc.us.us
203  %inc.lcssa.us.us = phi i32 [ %inc.us.us, %for.inc.us.us ]
204  store i32 %inc.lcssa.us.us, i32* @b, align 4
205  br label %for.cond2.loopexit.us.us
206
207for.inc.us.us:                                    ; preds = %for.inc.us.us, %for.inc.lr.ph.us.us
208  %5 = phi i32 [ %4, %for.inc.lr.ph.us.us ], [ %inc.us.us, %for.inc.us.us ]
209  %inc.us.us = add nsw i32 %5, 1
210  %cmp9.us.us = icmp slt i32 %inc.us.us, 1
211  br i1 %cmp9.us.us, label %for.inc.us.us, label %for.cond8.for.cond2.loopexit_crit_edge.us.us
212
213for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa.us: ; preds = %for.cond2.loopexit.us.us
214  %cond.lcssa.ph.us.ph.us = phi i32 [ %cond.us.us, %for.cond2.loopexit.us.us ]
215  br label %for.cond2.for.inc13_crit_edge.us-lcssa.us
216
217for.body3.lr.ph.split.us.split:                   ; preds = %for.body3.lr.ph.split.us.for.body3.lr.ph.split.us.split_crit_edge
218  br label %for.body3.us
219
220for.body3.us:                                     ; preds = %for.cond2.loopexit.us, %for.body3.lr.ph.split.us.split
221  br i1 true, label %cond.false.us, label %cond.end.us
222
223cond.false.us:                                    ; preds = %for.body3.us
224  br label %cond.end.us
225
226cond.end.us:                                      ; preds = %cond.false.us, %for.body3.us
227  %cond.us = phi i32 [ %div, %cond.false.us ], [ %conv7, %for.body3.us ]
228  %6 = load i32, i32* @b, align 4
229  %cmp91.us = icmp slt i32 %6, 1
230  br i1 %cmp91.us, label %for.inc.lr.ph.us, label %for.cond2.loopexit.us
231
232for.inc.us:                                       ; preds = %for.inc.lr.ph.us, %for.inc.us
233  %7 = phi i32 [ %6, %for.inc.lr.ph.us ], [ %inc.us, %for.inc.us ]
234  %inc.us = add nsw i32 %7, 1
235  %cmp9.us = icmp slt i32 %inc.us, 1
236  br i1 %cmp9.us, label %for.inc.us, label %for.cond8.for.cond2.loopexit_crit_edge.us
237
238for.cond2.loopexit.us:                            ; preds = %for.cond8.for.cond2.loopexit_crit_edge.us, %cond.end.us
239  br i1 false, label %for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa, label %for.body3.us
240
241for.inc.lr.ph.us:                                 ; preds = %cond.end.us
242  br label %for.inc.us
243
244for.cond8.for.cond2.loopexit_crit_edge.us:        ; preds = %for.inc.us
245  %inc.lcssa.us = phi i32 [ %inc.us, %for.inc.us ]
246  store i32 %inc.lcssa.us, i32* @b, align 4
247  br label %for.cond2.loopexit.us
248
249for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa: ; preds = %for.cond2.loopexit.us
250  %cond.lcssa.ph.us.ph = phi i32 [ %cond.us, %for.cond2.loopexit.us ]
251  br label %for.cond2.for.inc13_crit_edge.us-lcssa.us
252
253for.cond2.for.inc13_crit_edge.us-lcssa.us:        ; preds = %for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa, %for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa.us
254  %cond.lcssa.ph.us = phi i32 [ %cond.lcssa.ph.us.ph, %for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa ], [ %cond.lcssa.ph.us.ph.us, %for.cond2.for.inc13_crit_edge.us-lcssa.us.us-lcssa.us ]
255  br label %for.cond2.for.inc13_crit_edge
256
257for.body3.lr.ph.split:                            ; preds = %for.body3.lr.ph.for.body3.lr.ph.split_crit_edge
258  br i1 %tobool, label %for.body3.lr.ph.split.split.us, label %for.body3.lr.ph.split.for.body3.lr.ph.split.split_crit_edge
259
260for.body3.lr.ph.split.for.body3.lr.ph.split.split_crit_edge: ; preds = %for.body3.lr.ph.split
261  br label %for.body3.lr.ph.split.split
262
263for.body3.lr.ph.split.split.us:                   ; preds = %for.body3.lr.ph.split
264  br label %for.body3.us3
265
266for.body3.us3:                                    ; preds = %for.cond2.loopexit.us11, %for.body3.lr.ph.split.split.us
267  br i1 false, label %cond.false.us4, label %cond.end.us5
268
269cond.false.us4:                                   ; preds = %for.body3.us3
270  br label %cond.end.us5
271
272cond.end.us5:                                     ; preds = %cond.false.us4, %for.body3.us3
273  %cond.us6 = phi i32 [ %div, %cond.false.us4 ], [ %conv7, %for.body3.us3 ]
274  %8 = load i32, i32* @b, align 4
275  %cmp91.us7 = icmp slt i32 %8, 1
276  br i1 %cmp91.us7, label %for.inc.lr.ph.us12, label %for.cond2.loopexit.us11
277
278for.inc.us8:                                      ; preds = %for.inc.lr.ph.us12, %for.inc.us8
279  %9 = phi i32 [ %8, %for.inc.lr.ph.us12 ], [ %inc.us9, %for.inc.us8 ]
280  %inc.us9 = add nsw i32 %9, 1
281  %cmp9.us10 = icmp slt i32 %inc.us9, 1
282  br i1 %cmp9.us10, label %for.inc.us8, label %for.cond8.for.cond2.loopexit_crit_edge.us13
283
284for.cond2.loopexit.us11:                          ; preds = %for.cond8.for.cond2.loopexit_crit_edge.us13, %cond.end.us5
285  br i1 true, label %for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa.us, label %for.body3.us3
286
287for.inc.lr.ph.us12:                               ; preds = %cond.end.us5
288  br label %for.inc.us8
289
290for.cond8.for.cond2.loopexit_crit_edge.us13:      ; preds = %for.inc.us8
291  %inc.lcssa.us14 = phi i32 [ %inc.us9, %for.inc.us8 ]
292  store i32 %inc.lcssa.us14, i32* @b, align 4
293  br label %for.cond2.loopexit.us11
294
295for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa.us: ; preds = %for.cond2.loopexit.us11
296  %cond.lcssa.ph.ph.us = phi i32 [ %cond.us6, %for.cond2.loopexit.us11 ]
297  br label %for.cond2.for.inc13_crit_edge.us-lcssa
298
299for.body3.lr.ph.split.split:                      ; preds = %for.body3.lr.ph.split.for.body3.lr.ph.split.split_crit_edge
300  br label %for.body3
301
302for.cond8.for.cond2.loopexit_crit_edge:           ; preds = %for.inc
303  %inc.lcssa = phi i32 [ %inc, %for.inc ]
304  store i32 %inc.lcssa, i32* @b, align 4
305  br label %for.cond2.loopexit
306
307for.cond2.loopexit:                               ; preds = %cond.end, %for.cond8.for.cond2.loopexit_crit_edge
308  br i1 false, label %for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa, label %for.body3
309
310for.body3:                                        ; preds = %for.cond2.loopexit, %for.body3.lr.ph.split.split
311  br i1 false, label %cond.false, label %cond.end
312
313cond.false:                                       ; preds = %for.body3
314  br label %cond.end
315
316cond.end:                                         ; preds = %cond.false, %for.body3
317  %cond = phi i32 [ %div, %cond.false ], [ %conv7, %for.body3 ]
318  %10 = load i32, i32* @b, align 4
319  %cmp91 = icmp slt i32 %10, 1
320  br i1 %cmp91, label %for.inc.lr.ph, label %for.cond2.loopexit
321
322for.inc.lr.ph:                                    ; preds = %cond.end
323  br label %for.inc
324
325for.inc:                                          ; preds = %for.inc, %for.inc.lr.ph
326  %11 = phi i32 [ %10, %for.inc.lr.ph ], [ %inc, %for.inc ]
327  %inc = add nsw i32 %11, 1
328  %cmp9 = icmp slt i32 %inc, 1
329  br i1 %cmp9, label %for.inc, label %for.cond8.for.cond2.loopexit_crit_edge
330
331for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa:  ; preds = %for.cond2.loopexit
332  %cond.lcssa.ph.ph = phi i32 [ %cond, %for.cond2.loopexit ]
333  br label %for.cond2.for.inc13_crit_edge.us-lcssa
334
335for.cond2.for.inc13_crit_edge.us-lcssa:           ; preds = %for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa, %for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa.us
336  %cond.lcssa.ph = phi i32 [ %cond.lcssa.ph.ph, %for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa ], [ %cond.lcssa.ph.ph.us, %for.cond2.for.inc13_crit_edge.us-lcssa.us-lcssa.us ]
337  br label %for.cond2.for.inc13_crit_edge
338
339for.cond2.for.inc13_crit_edge:                    ; preds = %for.cond2.for.inc13_crit_edge.us-lcssa, %for.cond2.for.inc13_crit_edge.us-lcssa.us
340  %cond.lcssa = phi i32 [ %cond.lcssa.ph, %for.cond2.for.inc13_crit_edge.us-lcssa ], [ %cond.lcssa.ph.us, %for.cond2.for.inc13_crit_edge.us-lcssa.us ]
341  store i32 %cond.lcssa, i32* @c, align 4
342  br label %for.inc13
343
344for.inc13:                                        ; preds = %for.cond2.for.inc13_crit_edge, %for.cond2.preheader
345  %inc14 = add i8 %storemerge15, 1
346  %cmp = icmp ugt i8 %inc14, 50
347  br i1 %cmp, label %for.cond2.preheader, label %for.end15
348
349for.end15:                                        ; preds = %for.inc13
350  ret void
351}
352