1 ; RUN: opt %loadPolly -polly-codegen -S < %s | FileCheck %s
3 ; This caused an lnt crash at some point, just verify it will run through and
4 ; produce the PHI node in the exit we are looking for.
6 ; CHECK-LABEL: polly.merge_new_and_old:
7 ; CHECK-NEXT: %eps1.addr.0.ph.merge = phi double [ %eps1.addr.0.ph.final_reload, %polly.exiting ], [ %eps1.addr.0.ph, %if.end.47.region_exiting ]
8 ; CHECK-NEXT: br label %if.end.47
10 ; CHECK-LABEL: if.end.47:
11 ; CHECK-NEXT: %eps1.addr.0 = phi double [ %eps1.addr.0.ph.merge, %polly.merge_new_and_old ]
13 define void @dbisect(ptr %c, ptr %b, double %eps1, ptr %eps2) {
17 entry.split: ; preds = %entry
18 store double 0.000000e+00, ptr %b, align 8
19 %0 = load double, ptr %c, align 8
20 br i1 false, label %for.body.lr.ph, label %for.end
22 for.body.lr.ph: ; preds = %entry.split
25 for.body: ; preds = %for.inc, %for.body.lr.ph
26 br i1 false, label %if.then, label %if.end
28 if.then: ; preds = %for.body
31 if.end: ; preds = %if.then, %for.body
32 br i1 false, label %if.then.36, label %for.inc
34 if.then.36: ; preds = %if.end
37 for.inc: ; preds = %if.then.36, %if.end
38 br i1 false, label %for.body, label %for.cond.for.end_crit_edge
40 for.cond.for.end_crit_edge: ; preds = %for.inc
43 for.end: ; preds = %for.cond.for.end_crit_edge, %entry.split
44 store double undef, ptr %eps2, align 8
45 %cmp45 = fcmp ugt double %eps1, 0.000000e+00
46 br i1 %cmp45, label %if.end.47, label %if.then.46
48 if.then.46: ; preds = %for.end
51 if.end.47: ; preds = %if.then.46, %for.end
52 %eps1.addr.0 = phi double [ undef, %if.then.46 ], [ %eps1, %for.end ]
53 br i1 undef, label %if.then.55, label %for.cond.58.preheader
55 for.cond.58.preheader: ; preds = %if.end.47
56 br i1 undef, label %for.end.68, label %for.body.61.lr.ph
58 for.body.61.lr.ph: ; preds = %for.cond.58.preheader
61 if.then.55: ; preds = %if.end.47
64 for.body.61: ; preds = %for.body.61, %for.body.61.lr.ph
65 br i1 undef, label %for.body.61, label %for.cond.58.for.end.68_crit_edge
67 for.cond.58.for.end.68_crit_edge: ; preds = %for.body.61
70 for.end.68: ; preds = %for.cond.58.for.end.68_crit_edge, %for.cond.58.preheader
71 br i1 undef, label %for.end.137, label %for.cond.73.preheader.lr.ph
73 for.cond.73.preheader.lr.ph: ; preds = %for.end.68
74 br label %for.cond.73.preheader
76 for.cond.73.preheader: ; preds = %while.end, %for.cond.73.preheader.lr.ph
77 br i1 undef, label %for.end.87.loopexit, label %for.body.76.lr.ph
79 for.body.76.lr.ph: ; preds = %for.cond.73.preheader
82 for.body.76: ; preds = %for.inc.85, %for.body.76.lr.ph
83 br i1 undef, label %if.then.81, label %for.inc.85
85 if.then.81: ; preds = %for.body.76
88 for.inc.85: ; preds = %for.body.76
89 br i1 undef, label %for.body.76, label %for.cond.73.for.end.87.loopexit_crit_edge
91 for.cond.73.for.end.87.loopexit_crit_edge: ; preds = %for.inc.85
92 br label %for.end.87.loopexit
94 for.end.87.loopexit: ; preds = %for.cond.73.for.end.87.loopexit_crit_edge, %for.cond.73.preheader
97 for.end.87: ; preds = %for.end.87.loopexit, %if.then.81
98 br i1 undef, label %if.then.92, label %if.end.95
100 if.then.92: ; preds = %for.end.87
103 if.end.95: ; preds = %if.then.92, %for.end.87
104 br i1 undef, label %while.body.lr.ph, label %while.end
106 while.body.lr.ph: ; preds = %if.end.95
109 while.body: ; preds = %if.end.128, %while.body.lr.ph
110 br i1 undef, label %if.then.109, label %if.end.128
112 if.then.109: ; preds = %while.body
113 br i1 undef, label %if.then.112, label %if.else
115 if.then.112: ; preds = %if.then.109
118 if.else: ; preds = %if.then.109
119 br i1 undef, label %if.then.122, label %if.end.128
121 if.then.122: ; preds = %if.else
124 if.end.128: ; preds = %if.then.122, %if.else, %if.then.112, %while.body
125 br i1 undef, label %while.body, label %while.cond.while.end_crit_edge
127 while.cond.while.end_crit_edge: ; preds = %if.end.128
130 while.end: ; preds = %while.cond.while.end_crit_edge, %if.end.95
131 br i1 undef, label %for.cond.73.preheader, label %for.cond.69.for.end.137_crit_edge
133 for.cond.69.for.end.137_crit_edge: ; preds = %while.end
134 br label %for.end.137
136 for.end.137: ; preds = %for.cond.69.for.end.137_crit_edge, %for.end.68