1 // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --function-signature --include-generated-funcs --replace-value-regex "__omp_offloading_[0-9a-z]+_[0-9a-z]+" "reduction_size[.].+[.]" "pl_cond[.].+[.|,]" --prefix-filecheck-ir-name _
2 // RUN: %clang_cc1 -verify -triple x86_64-pc-linux-gnu -fopenmp -emit-llvm %s -o - | FileCheck %s --check-prefix=IR
4 // Check same results after serialization round-trip
5 // RUN: %clang_cc1 -verify -triple x86_64-pc-linux-gnu -fopenmp -emit-pch -o %t %s
6 // RUN: %clang_cc1 -verify -triple x86_64-pc-linux-gnu -fopenmp -include-pch %t -emit-llvm %s -o - | FileCheck %s --check-prefix=IR-PCH
8 // expected-no-diagnostics
17 #pragma omp teams loop reduction(+:sum) collapse(2) bind(parallel) \
18 order(concurrent) lastprivate(j)
26 // IR-LABEL: define {{[^@]+}}@_Z3foov
27 // IR-SAME: () #[[ATTR0:[0-9]+]] {
29 // IR-NEXT: [[I:%.*]] = alloca i32, align 4
30 // IR-NEXT: [[J:%.*]] = alloca i32, align 4
31 // IR-NEXT: [[SUM:%.*]] = alloca [10 x [10 x i32]], align 16
32 // IR-NEXT: call void (ptr, i32, ptr, ...) @__kmpc_fork_teams(ptr @[[GLOB3:[0-9]+]], i32 2, ptr @_Z3foov.omp_outlined, ptr [[J]], ptr [[SUM]])
36 // IR-LABEL: define {{[^@]+}}@_Z3foov.omp_outlined
37 // IR-SAME: (ptr noalias noundef [[DOTGLOBAL_TID_:%.*]], ptr noalias noundef [[DOTBOUND_TID_:%.*]], ptr noundef nonnull align 4 dereferenceable(4) [[J:%.*]], ptr noundef nonnull align 4 dereferenceable(400) [[SUM:%.*]]) #[[ATTR1:[0-9]+]] {
39 // IR-NEXT: [[DOTGLOBAL_TID__ADDR:%.*]] = alloca ptr, align 8
40 // IR-NEXT: [[DOTBOUND_TID__ADDR:%.*]] = alloca ptr, align 8
41 // IR-NEXT: [[J_ADDR:%.*]] = alloca ptr, align 8
42 // IR-NEXT: [[SUM_ADDR:%.*]] = alloca ptr, align 8
43 // IR-NEXT: [[SUM1:%.*]] = alloca [10 x [10 x i32]], align 16
44 // IR-NEXT: [[DOTOMP_IV:%.*]] = alloca i32, align 4
45 // IR-NEXT: [[TMP:%.*]] = alloca i32, align 4
46 // IR-NEXT: [[_TMP2:%.*]] = alloca i32, align 4
47 // IR-NEXT: [[DOTOMP_COMB_LB:%.*]] = alloca i32, align 4
48 // IR-NEXT: [[DOTOMP_COMB_UB:%.*]] = alloca i32, align 4
49 // IR-NEXT: [[DOTOMP_STRIDE:%.*]] = alloca i32, align 4
50 // IR-NEXT: [[DOTOMP_IS_LAST:%.*]] = alloca i32, align 4
51 // IR-NEXT: [[J3:%.*]] = alloca i32, align 4
52 // IR-NEXT: [[I:%.*]] = alloca i32, align 4
53 // IR-NEXT: [[J4:%.*]] = alloca i32, align 4
54 // IR-NEXT: [[DOTOMP_REDUCTION_RED_LIST:%.*]] = alloca [1 x ptr], align 8
55 // IR-NEXT: store ptr [[DOTGLOBAL_TID_]], ptr [[DOTGLOBAL_TID__ADDR]], align 8
56 // IR-NEXT: store ptr [[DOTBOUND_TID_]], ptr [[DOTBOUND_TID__ADDR]], align 8
57 // IR-NEXT: store ptr [[J]], ptr [[J_ADDR]], align 8
58 // IR-NEXT: store ptr [[SUM]], ptr [[SUM_ADDR]], align 8
59 // IR-NEXT: [[TMP0:%.*]] = load ptr, ptr [[J_ADDR]], align 8
60 // IR-NEXT: [[TMP1:%.*]] = load ptr, ptr [[SUM_ADDR]], align 8
61 // IR-NEXT: [[ARRAY_BEGIN:%.*]] = getelementptr inbounds [10 x [10 x i32]], ptr [[SUM1]], i32 0, i32 0, i32 0
62 // IR-NEXT: [[TMP2:%.*]] = getelementptr i32, ptr [[ARRAY_BEGIN]], i64 100
63 // IR-NEXT: [[OMP_ARRAYINIT_ISEMPTY:%.*]] = icmp eq ptr [[ARRAY_BEGIN]], [[TMP2]]
64 // IR-NEXT: br i1 [[OMP_ARRAYINIT_ISEMPTY]], label [[OMP_ARRAYINIT_DONE:%.*]], label [[OMP_ARRAYINIT_BODY:%.*]]
65 // IR: omp.arrayinit.body:
66 // IR-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST:%.*]] = phi ptr [ [[ARRAY_BEGIN]], [[ENTRY:%.*]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT:%.*]], [[OMP_ARRAYINIT_BODY]] ]
67 // IR-NEXT: store i32 0, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], align 4
68 // IR-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], i32 1
69 // IR-NEXT: [[OMP_ARRAYCPY_DONE:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT]], [[TMP2]]
70 // IR-NEXT: br i1 [[OMP_ARRAYCPY_DONE]], label [[OMP_ARRAYINIT_DONE]], label [[OMP_ARRAYINIT_BODY]]
71 // IR: omp.arrayinit.done:
72 // IR-NEXT: store i32 0, ptr [[DOTOMP_COMB_LB]], align 4
73 // IR-NEXT: store i32 99, ptr [[DOTOMP_COMB_UB]], align 4
74 // IR-NEXT: store i32 1, ptr [[DOTOMP_STRIDE]], align 4
75 // IR-NEXT: store i32 0, ptr [[DOTOMP_IS_LAST]], align 4
76 // IR-NEXT: [[TMP3:%.*]] = load ptr, ptr [[DOTGLOBAL_TID__ADDR]], align 8
77 // IR-NEXT: [[TMP4:%.*]] = load i32, ptr [[TMP3]], align 4
78 // IR-NEXT: call void @__kmpc_for_static_init_4(ptr @[[GLOB1:[0-9]+]], i32 [[TMP4]], i32 92, ptr [[DOTOMP_IS_LAST]], ptr [[DOTOMP_COMB_LB]], ptr [[DOTOMP_COMB_UB]], ptr [[DOTOMP_STRIDE]], i32 1, i32 1)
79 // IR-NEXT: [[TMP5:%.*]] = load i32, ptr [[DOTOMP_COMB_UB]], align 4
80 // IR-NEXT: [[CMP:%.*]] = icmp sgt i32 [[TMP5]], 99
81 // IR-NEXT: br i1 [[CMP]], label [[COND_TRUE:%.*]], label [[COND_FALSE:%.*]]
83 // IR-NEXT: br label [[COND_END:%.*]]
85 // IR-NEXT: [[TMP6:%.*]] = load i32, ptr [[DOTOMP_COMB_UB]], align 4
86 // IR-NEXT: br label [[COND_END]]
88 // IR-NEXT: [[COND:%.*]] = phi i32 [ 99, [[COND_TRUE]] ], [ [[TMP6]], [[COND_FALSE]] ]
89 // IR-NEXT: store i32 [[COND]], ptr [[DOTOMP_COMB_UB]], align 4
90 // IR-NEXT: [[TMP7:%.*]] = load i32, ptr [[DOTOMP_COMB_LB]], align 4
91 // IR-NEXT: store i32 [[TMP7]], ptr [[DOTOMP_IV]], align 4
92 // IR-NEXT: br label [[OMP_INNER_FOR_COND:%.*]]
93 // IR: omp.inner.for.cond:
94 // IR-NEXT: [[TMP8:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
95 // IR-NEXT: [[TMP9:%.*]] = load i32, ptr [[DOTOMP_COMB_UB]], align 4
96 // IR-NEXT: [[CMP5:%.*]] = icmp sle i32 [[TMP8]], [[TMP9]]
97 // IR-NEXT: br i1 [[CMP5]], label [[OMP_INNER_FOR_BODY:%.*]], label [[OMP_INNER_FOR_END:%.*]]
98 // IR: omp.inner.for.body:
99 // IR-NEXT: [[TMP10:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
100 // IR-NEXT: [[DIV:%.*]] = sdiv i32 [[TMP10]], 10
101 // IR-NEXT: [[MUL:%.*]] = mul nsw i32 [[DIV]], 1
102 // IR-NEXT: [[ADD:%.*]] = add nsw i32 0, [[MUL]]
103 // IR-NEXT: store i32 [[ADD]], ptr [[I]], align 4
104 // IR-NEXT: [[TMP11:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
105 // IR-NEXT: [[TMP12:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
106 // IR-NEXT: [[DIV6:%.*]] = sdiv i32 [[TMP12]], 10
107 // IR-NEXT: [[MUL7:%.*]] = mul nsw i32 [[DIV6]], 10
108 // IR-NEXT: [[SUB:%.*]] = sub nsw i32 [[TMP11]], [[MUL7]]
109 // IR-NEXT: [[MUL8:%.*]] = mul nsw i32 [[SUB]], 1
110 // IR-NEXT: [[ADD9:%.*]] = add nsw i32 0, [[MUL8]]
111 // IR-NEXT: store i32 [[ADD9]], ptr [[J3]], align 4
112 // IR-NEXT: [[TMP13:%.*]] = load i32, ptr [[I]], align 4
113 // IR-NEXT: [[TMP14:%.*]] = load i32, ptr [[I]], align 4
114 // IR-NEXT: [[IDXPROM:%.*]] = sext i32 [[TMP14]] to i64
115 // IR-NEXT: [[ARRAYIDX:%.*]] = getelementptr inbounds [10 x [10 x i32]], ptr [[SUM1]], i64 0, i64 [[IDXPROM]]
116 // IR-NEXT: [[TMP15:%.*]] = load i32, ptr [[J3]], align 4
117 // IR-NEXT: [[IDXPROM10:%.*]] = sext i32 [[TMP15]] to i64
118 // IR-NEXT: [[ARRAYIDX11:%.*]] = getelementptr inbounds [10 x i32], ptr [[ARRAYIDX]], i64 0, i64 [[IDXPROM10]]
119 // IR-NEXT: [[TMP16:%.*]] = load i32, ptr [[ARRAYIDX11]], align 4
120 // IR-NEXT: [[ADD12:%.*]] = add nsw i32 [[TMP16]], [[TMP13]]
121 // IR-NEXT: store i32 [[ADD12]], ptr [[ARRAYIDX11]], align 4
122 // IR-NEXT: br label [[OMP_BODY_CONTINUE:%.*]]
123 // IR: omp.body.continue:
124 // IR-NEXT: br label [[OMP_INNER_FOR_INC:%.*]]
125 // IR: omp.inner.for.inc:
126 // IR-NEXT: [[TMP17:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
127 // IR-NEXT: [[ADD13:%.*]] = add nsw i32 [[TMP17]], 1
128 // IR-NEXT: store i32 [[ADD13]], ptr [[DOTOMP_IV]], align 4
129 // IR-NEXT: br label [[OMP_INNER_FOR_COND]]
130 // IR: omp.inner.for.end:
131 // IR-NEXT: br label [[OMP_LOOP_EXIT:%.*]]
132 // IR: omp.loop.exit:
133 // IR-NEXT: [[TMP18:%.*]] = load ptr, ptr [[DOTGLOBAL_TID__ADDR]], align 8
134 // IR-NEXT: [[TMP19:%.*]] = load i32, ptr [[TMP18]], align 4
135 // IR-NEXT: call void @__kmpc_for_static_fini(ptr @[[GLOB1]], i32 [[TMP19]])
136 // IR-NEXT: [[TMP20:%.*]] = load i32, ptr [[DOTOMP_IS_LAST]], align 4
137 // IR-NEXT: [[TMP21:%.*]] = icmp ne i32 [[TMP20]], 0
138 // IR-NEXT: br i1 [[TMP21]], label [[DOTOMP_LASTPRIVATE_THEN:%.*]], label [[DOTOMP_LASTPRIVATE_DONE:%.*]]
139 // IR: .omp.lastprivate.then:
140 // IR-NEXT: store i32 10, ptr [[J3]], align 4
141 // IR-NEXT: [[TMP22:%.*]] = load i32, ptr [[J3]], align 4
142 // IR-NEXT: store i32 [[TMP22]], ptr [[TMP0]], align 4
143 // IR-NEXT: br label [[DOTOMP_LASTPRIVATE_DONE]]
144 // IR: .omp.lastprivate.done:
145 // IR-NEXT: [[TMP23:%.*]] = getelementptr inbounds [1 x ptr], ptr [[DOTOMP_REDUCTION_RED_LIST]], i64 0, i64 0
146 // IR-NEXT: store ptr [[SUM1]], ptr [[TMP23]], align 8
147 // IR-NEXT: [[TMP24:%.*]] = load ptr, ptr [[DOTGLOBAL_TID__ADDR]], align 8
148 // IR-NEXT: [[TMP25:%.*]] = load i32, ptr [[TMP24]], align 4
149 // IR-NEXT: [[TMP26:%.*]] = call i32 @__kmpc_reduce_nowait(ptr @[[GLOB2:[0-9]+]], i32 [[TMP25]], i32 1, i64 8, ptr [[DOTOMP_REDUCTION_RED_LIST]], ptr @_Z3foov.omp_outlined.omp.reduction.reduction_func, ptr @.gomp_critical_user_.reduction.var)
150 // IR-NEXT: switch i32 [[TMP26]], label [[DOTOMP_REDUCTION_DEFAULT:%.*]] [
151 // IR-NEXT: i32 1, label [[DOTOMP_REDUCTION_CASE1:%.*]]
152 // IR-NEXT: i32 2, label [[DOTOMP_REDUCTION_CASE2:%.*]]
154 // IR: .omp.reduction.case1:
155 // IR-NEXT: [[TMP27:%.*]] = getelementptr i32, ptr [[TMP1]], i64 100
156 // IR-NEXT: [[OMP_ARRAYCPY_ISEMPTY:%.*]] = icmp eq ptr [[TMP1]], [[TMP27]]
157 // IR-NEXT: br i1 [[OMP_ARRAYCPY_ISEMPTY]], label [[OMP_ARRAYCPY_DONE18:%.*]], label [[OMP_ARRAYCPY_BODY:%.*]]
158 // IR: omp.arraycpy.body:
159 // IR-NEXT: [[OMP_ARRAYCPY_SRCELEMENTPAST:%.*]] = phi ptr [ [[SUM1]], [[DOTOMP_REDUCTION_CASE1]] ], [ [[OMP_ARRAYCPY_SRC_ELEMENT:%.*]], [[OMP_ARRAYCPY_BODY]] ]
160 // IR-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST14:%.*]] = phi ptr [ [[TMP1]], [[DOTOMP_REDUCTION_CASE1]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT16:%.*]], [[OMP_ARRAYCPY_BODY]] ]
161 // IR-NEXT: [[TMP28:%.*]] = load i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST14]], align 4
162 // IR-NEXT: [[TMP29:%.*]] = load i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], align 4
163 // IR-NEXT: [[ADD15:%.*]] = add nsw i32 [[TMP28]], [[TMP29]]
164 // IR-NEXT: store i32 [[ADD15]], ptr [[OMP_ARRAYCPY_DESTELEMENTPAST14]], align 4
165 // IR-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT16]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST14]], i32 1
166 // IR-NEXT: [[OMP_ARRAYCPY_SRC_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], i32 1
167 // IR-NEXT: [[OMP_ARRAYCPY_DONE17:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT16]], [[TMP27]]
168 // IR-NEXT: br i1 [[OMP_ARRAYCPY_DONE17]], label [[OMP_ARRAYCPY_DONE18]], label [[OMP_ARRAYCPY_BODY]]
169 // IR: omp.arraycpy.done18:
170 // IR-NEXT: call void @__kmpc_end_reduce_nowait(ptr @[[GLOB2]], i32 [[TMP25]], ptr @.gomp_critical_user_.reduction.var)
171 // IR-NEXT: br label [[DOTOMP_REDUCTION_DEFAULT]]
172 // IR: .omp.reduction.case2:
173 // IR-NEXT: [[TMP30:%.*]] = getelementptr i32, ptr [[TMP1]], i64 100
174 // IR-NEXT: [[OMP_ARRAYCPY_ISEMPTY19:%.*]] = icmp eq ptr [[TMP1]], [[TMP30]]
175 // IR-NEXT: br i1 [[OMP_ARRAYCPY_ISEMPTY19]], label [[OMP_ARRAYCPY_DONE26:%.*]], label [[OMP_ARRAYCPY_BODY20:%.*]]
176 // IR: omp.arraycpy.body20:
177 // IR-NEXT: [[OMP_ARRAYCPY_SRCELEMENTPAST21:%.*]] = phi ptr [ [[SUM1]], [[DOTOMP_REDUCTION_CASE2]] ], [ [[OMP_ARRAYCPY_SRC_ELEMENT24:%.*]], [[OMP_ARRAYCPY_BODY20]] ]
178 // IR-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST22:%.*]] = phi ptr [ [[TMP1]], [[DOTOMP_REDUCTION_CASE2]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT23:%.*]], [[OMP_ARRAYCPY_BODY20]] ]
179 // IR-NEXT: [[TMP31:%.*]] = load i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST21]], align 4
180 // IR-NEXT: [[TMP32:%.*]] = atomicrmw add ptr [[OMP_ARRAYCPY_DESTELEMENTPAST22]], i32 [[TMP31]] monotonic, align 4
181 // IR-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT23]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST22]], i32 1
182 // IR-NEXT: [[OMP_ARRAYCPY_SRC_ELEMENT24]] = getelementptr i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST21]], i32 1
183 // IR-NEXT: [[OMP_ARRAYCPY_DONE25:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT23]], [[TMP30]]
184 // IR-NEXT: br i1 [[OMP_ARRAYCPY_DONE25]], label [[OMP_ARRAYCPY_DONE26]], label [[OMP_ARRAYCPY_BODY20]]
185 // IR: omp.arraycpy.done26:
186 // IR-NEXT: br label [[DOTOMP_REDUCTION_DEFAULT]]
187 // IR: .omp.reduction.default:
191 // IR-LABEL: define {{[^@]+}}@_Z3foov.omp_outlined.omp.reduction.reduction_func
192 // IR-SAME: (ptr noundef [[TMP0:%.*]], ptr noundef [[TMP1:%.*]]) #[[ATTR3:[0-9]+]] {
194 // IR-NEXT: [[DOTADDR:%.*]] = alloca ptr, align 8
195 // IR-NEXT: [[DOTADDR1:%.*]] = alloca ptr, align 8
196 // IR-NEXT: store ptr [[TMP0]], ptr [[DOTADDR]], align 8
197 // IR-NEXT: store ptr [[TMP1]], ptr [[DOTADDR1]], align 8
198 // IR-NEXT: [[TMP2:%.*]] = load ptr, ptr [[DOTADDR]], align 8
199 // IR-NEXT: [[TMP3:%.*]] = load ptr, ptr [[DOTADDR1]], align 8
200 // IR-NEXT: [[TMP4:%.*]] = getelementptr inbounds [1 x ptr], ptr [[TMP3]], i64 0, i64 0
201 // IR-NEXT: [[TMP5:%.*]] = load ptr, ptr [[TMP4]], align 8
202 // IR-NEXT: [[TMP6:%.*]] = getelementptr inbounds [1 x ptr], ptr [[TMP2]], i64 0, i64 0
203 // IR-NEXT: [[TMP7:%.*]] = load ptr, ptr [[TMP6]], align 8
204 // IR-NEXT: [[TMP8:%.*]] = getelementptr i32, ptr [[TMP7]], i64 100
205 // IR-NEXT: [[OMP_ARRAYCPY_ISEMPTY:%.*]] = icmp eq ptr [[TMP7]], [[TMP8]]
206 // IR-NEXT: br i1 [[OMP_ARRAYCPY_ISEMPTY]], label [[OMP_ARRAYCPY_DONE2:%.*]], label [[OMP_ARRAYCPY_BODY:%.*]]
207 // IR: omp.arraycpy.body:
208 // IR-NEXT: [[OMP_ARRAYCPY_SRCELEMENTPAST:%.*]] = phi ptr [ [[TMP5]], [[ENTRY:%.*]] ], [ [[OMP_ARRAYCPY_SRC_ELEMENT:%.*]], [[OMP_ARRAYCPY_BODY]] ]
209 // IR-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST:%.*]] = phi ptr [ [[TMP7]], [[ENTRY]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT:%.*]], [[OMP_ARRAYCPY_BODY]] ]
210 // IR-NEXT: [[TMP9:%.*]] = load i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], align 4
211 // IR-NEXT: [[TMP10:%.*]] = load i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], align 4
212 // IR-NEXT: [[ADD:%.*]] = add nsw i32 [[TMP9]], [[TMP10]]
213 // IR-NEXT: store i32 [[ADD]], ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], align 4
214 // IR-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], i32 1
215 // IR-NEXT: [[OMP_ARRAYCPY_SRC_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], i32 1
216 // IR-NEXT: [[OMP_ARRAYCPY_DONE:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT]], [[TMP8]]
217 // IR-NEXT: br i1 [[OMP_ARRAYCPY_DONE]], label [[OMP_ARRAYCPY_DONE2]], label [[OMP_ARRAYCPY_BODY]]
218 // IR: omp.arraycpy.done2:
222 // IR-PCH-LABEL: define {{[^@]+}}@_Z3foov
223 // IR-PCH-SAME: () #[[ATTR0:[0-9]+]] {
224 // IR-PCH-NEXT: entry:
225 // IR-PCH-NEXT: [[I:%.*]] = alloca i32, align 4
226 // IR-PCH-NEXT: [[J:%.*]] = alloca i32, align 4
227 // IR-PCH-NEXT: [[SUM:%.*]] = alloca [10 x [10 x i32]], align 16
228 // IR-PCH-NEXT: call void (ptr, i32, ptr, ...) @__kmpc_fork_teams(ptr @[[GLOB3:[0-9]+]], i32 2, ptr @_Z3foov.omp_outlined, ptr [[J]], ptr [[SUM]])
229 // IR-PCH-NEXT: ret i32 0
232 // IR-PCH-LABEL: define {{[^@]+}}@_Z3foov.omp_outlined
233 // IR-PCH-SAME: (ptr noalias noundef [[DOTGLOBAL_TID_:%.*]], ptr noalias noundef [[DOTBOUND_TID_:%.*]], ptr noundef nonnull align 4 dereferenceable(4) [[J:%.*]], ptr noundef nonnull align 4 dereferenceable(400) [[SUM:%.*]]) #[[ATTR1:[0-9]+]] {
234 // IR-PCH-NEXT: entry:
235 // IR-PCH-NEXT: [[DOTGLOBAL_TID__ADDR:%.*]] = alloca ptr, align 8
236 // IR-PCH-NEXT: [[DOTBOUND_TID__ADDR:%.*]] = alloca ptr, align 8
237 // IR-PCH-NEXT: [[J_ADDR:%.*]] = alloca ptr, align 8
238 // IR-PCH-NEXT: [[SUM_ADDR:%.*]] = alloca ptr, align 8
239 // IR-PCH-NEXT: [[SUM1:%.*]] = alloca [10 x [10 x i32]], align 16
240 // IR-PCH-NEXT: [[DOTOMP_IV:%.*]] = alloca i32, align 4
241 // IR-PCH-NEXT: [[TMP:%.*]] = alloca i32, align 4
242 // IR-PCH-NEXT: [[_TMP2:%.*]] = alloca i32, align 4
243 // IR-PCH-NEXT: [[DOTOMP_COMB_LB:%.*]] = alloca i32, align 4
244 // IR-PCH-NEXT: [[DOTOMP_COMB_UB:%.*]] = alloca i32, align 4
245 // IR-PCH-NEXT: [[DOTOMP_STRIDE:%.*]] = alloca i32, align 4
246 // IR-PCH-NEXT: [[DOTOMP_IS_LAST:%.*]] = alloca i32, align 4
247 // IR-PCH-NEXT: [[J3:%.*]] = alloca i32, align 4
248 // IR-PCH-NEXT: [[I:%.*]] = alloca i32, align 4
249 // IR-PCH-NEXT: [[J4:%.*]] = alloca i32, align 4
250 // IR-PCH-NEXT: [[DOTOMP_REDUCTION_RED_LIST:%.*]] = alloca [1 x ptr], align 8
251 // IR-PCH-NEXT: store ptr [[DOTGLOBAL_TID_]], ptr [[DOTGLOBAL_TID__ADDR]], align 8
252 // IR-PCH-NEXT: store ptr [[DOTBOUND_TID_]], ptr [[DOTBOUND_TID__ADDR]], align 8
253 // IR-PCH-NEXT: store ptr [[J]], ptr [[J_ADDR]], align 8
254 // IR-PCH-NEXT: store ptr [[SUM]], ptr [[SUM_ADDR]], align 8
255 // IR-PCH-NEXT: [[TMP0:%.*]] = load ptr, ptr [[J_ADDR]], align 8
256 // IR-PCH-NEXT: [[TMP1:%.*]] = load ptr, ptr [[SUM_ADDR]], align 8
257 // IR-PCH-NEXT: [[ARRAY_BEGIN:%.*]] = getelementptr inbounds [10 x [10 x i32]], ptr [[SUM1]], i32 0, i32 0, i32 0
258 // IR-PCH-NEXT: [[TMP2:%.*]] = getelementptr i32, ptr [[ARRAY_BEGIN]], i64 100
259 // IR-PCH-NEXT: [[OMP_ARRAYINIT_ISEMPTY:%.*]] = icmp eq ptr [[ARRAY_BEGIN]], [[TMP2]]
260 // IR-PCH-NEXT: br i1 [[OMP_ARRAYINIT_ISEMPTY]], label [[OMP_ARRAYINIT_DONE:%.*]], label [[OMP_ARRAYINIT_BODY:%.*]]
261 // IR-PCH: omp.arrayinit.body:
262 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST:%.*]] = phi ptr [ [[ARRAY_BEGIN]], [[ENTRY:%.*]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT:%.*]], [[OMP_ARRAYINIT_BODY]] ]
263 // IR-PCH-NEXT: store i32 0, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], align 4
264 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], i32 1
265 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DONE:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT]], [[TMP2]]
266 // IR-PCH-NEXT: br i1 [[OMP_ARRAYCPY_DONE]], label [[OMP_ARRAYINIT_DONE]], label [[OMP_ARRAYINIT_BODY]]
267 // IR-PCH: omp.arrayinit.done:
268 // IR-PCH-NEXT: store i32 0, ptr [[DOTOMP_COMB_LB]], align 4
269 // IR-PCH-NEXT: store i32 99, ptr [[DOTOMP_COMB_UB]], align 4
270 // IR-PCH-NEXT: store i32 1, ptr [[DOTOMP_STRIDE]], align 4
271 // IR-PCH-NEXT: store i32 0, ptr [[DOTOMP_IS_LAST]], align 4
272 // IR-PCH-NEXT: [[TMP3:%.*]] = load ptr, ptr [[DOTGLOBAL_TID__ADDR]], align 8
273 // IR-PCH-NEXT: [[TMP4:%.*]] = load i32, ptr [[TMP3]], align 4
274 // IR-PCH-NEXT: call void @__kmpc_for_static_init_4(ptr @[[GLOB1:[0-9]+]], i32 [[TMP4]], i32 92, ptr [[DOTOMP_IS_LAST]], ptr [[DOTOMP_COMB_LB]], ptr [[DOTOMP_COMB_UB]], ptr [[DOTOMP_STRIDE]], i32 1, i32 1)
275 // IR-PCH-NEXT: [[TMP5:%.*]] = load i32, ptr [[DOTOMP_COMB_UB]], align 4
276 // IR-PCH-NEXT: [[CMP:%.*]] = icmp sgt i32 [[TMP5]], 99
277 // IR-PCH-NEXT: br i1 [[CMP]], label [[COND_TRUE:%.*]], label [[COND_FALSE:%.*]]
278 // IR-PCH: cond.true:
279 // IR-PCH-NEXT: br label [[COND_END:%.*]]
280 // IR-PCH: cond.false:
281 // IR-PCH-NEXT: [[TMP6:%.*]] = load i32, ptr [[DOTOMP_COMB_UB]], align 4
282 // IR-PCH-NEXT: br label [[COND_END]]
284 // IR-PCH-NEXT: [[COND:%.*]] = phi i32 [ 99, [[COND_TRUE]] ], [ [[TMP6]], [[COND_FALSE]] ]
285 // IR-PCH-NEXT: store i32 [[COND]], ptr [[DOTOMP_COMB_UB]], align 4
286 // IR-PCH-NEXT: [[TMP7:%.*]] = load i32, ptr [[DOTOMP_COMB_LB]], align 4
287 // IR-PCH-NEXT: store i32 [[TMP7]], ptr [[DOTOMP_IV]], align 4
288 // IR-PCH-NEXT: br label [[OMP_INNER_FOR_COND:%.*]]
289 // IR-PCH: omp.inner.for.cond:
290 // IR-PCH-NEXT: [[TMP8:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
291 // IR-PCH-NEXT: [[TMP9:%.*]] = load i32, ptr [[DOTOMP_COMB_UB]], align 4
292 // IR-PCH-NEXT: [[CMP5:%.*]] = icmp sle i32 [[TMP8]], [[TMP9]]
293 // IR-PCH-NEXT: br i1 [[CMP5]], label [[OMP_INNER_FOR_BODY:%.*]], label [[OMP_INNER_FOR_END:%.*]]
294 // IR-PCH: omp.inner.for.body:
295 // IR-PCH-NEXT: [[TMP10:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
296 // IR-PCH-NEXT: [[DIV:%.*]] = sdiv i32 [[TMP10]], 10
297 // IR-PCH-NEXT: [[MUL:%.*]] = mul nsw i32 [[DIV]], 1
298 // IR-PCH-NEXT: [[ADD:%.*]] = add nsw i32 0, [[MUL]]
299 // IR-PCH-NEXT: store i32 [[ADD]], ptr [[I]], align 4
300 // IR-PCH-NEXT: [[TMP11:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
301 // IR-PCH-NEXT: [[TMP12:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
302 // IR-PCH-NEXT: [[DIV6:%.*]] = sdiv i32 [[TMP12]], 10
303 // IR-PCH-NEXT: [[MUL7:%.*]] = mul nsw i32 [[DIV6]], 10
304 // IR-PCH-NEXT: [[SUB:%.*]] = sub nsw i32 [[TMP11]], [[MUL7]]
305 // IR-PCH-NEXT: [[MUL8:%.*]] = mul nsw i32 [[SUB]], 1
306 // IR-PCH-NEXT: [[ADD9:%.*]] = add nsw i32 0, [[MUL8]]
307 // IR-PCH-NEXT: store i32 [[ADD9]], ptr [[J3]], align 4
308 // IR-PCH-NEXT: [[TMP13:%.*]] = load i32, ptr [[I]], align 4
309 // IR-PCH-NEXT: [[TMP14:%.*]] = load i32, ptr [[I]], align 4
310 // IR-PCH-NEXT: [[IDXPROM:%.*]] = sext i32 [[TMP14]] to i64
311 // IR-PCH-NEXT: [[ARRAYIDX:%.*]] = getelementptr inbounds [10 x [10 x i32]], ptr [[SUM1]], i64 0, i64 [[IDXPROM]]
312 // IR-PCH-NEXT: [[TMP15:%.*]] = load i32, ptr [[J3]], align 4
313 // IR-PCH-NEXT: [[IDXPROM10:%.*]] = sext i32 [[TMP15]] to i64
314 // IR-PCH-NEXT: [[ARRAYIDX11:%.*]] = getelementptr inbounds [10 x i32], ptr [[ARRAYIDX]], i64 0, i64 [[IDXPROM10]]
315 // IR-PCH-NEXT: [[TMP16:%.*]] = load i32, ptr [[ARRAYIDX11]], align 4
316 // IR-PCH-NEXT: [[ADD12:%.*]] = add nsw i32 [[TMP16]], [[TMP13]]
317 // IR-PCH-NEXT: store i32 [[ADD12]], ptr [[ARRAYIDX11]], align 4
318 // IR-PCH-NEXT: br label [[OMP_BODY_CONTINUE:%.*]]
319 // IR-PCH: omp.body.continue:
320 // IR-PCH-NEXT: br label [[OMP_INNER_FOR_INC:%.*]]
321 // IR-PCH: omp.inner.for.inc:
322 // IR-PCH-NEXT: [[TMP17:%.*]] = load i32, ptr [[DOTOMP_IV]], align 4
323 // IR-PCH-NEXT: [[ADD13:%.*]] = add nsw i32 [[TMP17]], 1
324 // IR-PCH-NEXT: store i32 [[ADD13]], ptr [[DOTOMP_IV]], align 4
325 // IR-PCH-NEXT: br label [[OMP_INNER_FOR_COND]]
326 // IR-PCH: omp.inner.for.end:
327 // IR-PCH-NEXT: br label [[OMP_LOOP_EXIT:%.*]]
328 // IR-PCH: omp.loop.exit:
329 // IR-PCH-NEXT: [[TMP18:%.*]] = load ptr, ptr [[DOTGLOBAL_TID__ADDR]], align 8
330 // IR-PCH-NEXT: [[TMP19:%.*]] = load i32, ptr [[TMP18]], align 4
331 // IR-PCH-NEXT: call void @__kmpc_for_static_fini(ptr @[[GLOB1]], i32 [[TMP19]])
332 // IR-PCH-NEXT: [[TMP20:%.*]] = load i32, ptr [[DOTOMP_IS_LAST]], align 4
333 // IR-PCH-NEXT: [[TMP21:%.*]] = icmp ne i32 [[TMP20]], 0
334 // IR-PCH-NEXT: br i1 [[TMP21]], label [[DOTOMP_LASTPRIVATE_THEN:%.*]], label [[DOTOMP_LASTPRIVATE_DONE:%.*]]
335 // IR-PCH: .omp.lastprivate.then:
336 // IR-PCH-NEXT: store i32 10, ptr [[J3]], align 4
337 // IR-PCH-NEXT: [[TMP22:%.*]] = load i32, ptr [[J3]], align 4
338 // IR-PCH-NEXT: store i32 [[TMP22]], ptr [[TMP0]], align 4
339 // IR-PCH-NEXT: br label [[DOTOMP_LASTPRIVATE_DONE]]
340 // IR-PCH: .omp.lastprivate.done:
341 // IR-PCH-NEXT: [[TMP23:%.*]] = getelementptr inbounds [1 x ptr], ptr [[DOTOMP_REDUCTION_RED_LIST]], i64 0, i64 0
342 // IR-PCH-NEXT: store ptr [[SUM1]], ptr [[TMP23]], align 8
343 // IR-PCH-NEXT: [[TMP24:%.*]] = load ptr, ptr [[DOTGLOBAL_TID__ADDR]], align 8
344 // IR-PCH-NEXT: [[TMP25:%.*]] = load i32, ptr [[TMP24]], align 4
345 // IR-PCH-NEXT: [[TMP26:%.*]] = call i32 @__kmpc_reduce_nowait(ptr @[[GLOB2:[0-9]+]], i32 [[TMP25]], i32 1, i64 8, ptr [[DOTOMP_REDUCTION_RED_LIST]], ptr @_Z3foov.omp_outlined.omp.reduction.reduction_func, ptr @.gomp_critical_user_.reduction.var)
346 // IR-PCH-NEXT: switch i32 [[TMP26]], label [[DOTOMP_REDUCTION_DEFAULT:%.*]] [
347 // IR-PCH-NEXT: i32 1, label [[DOTOMP_REDUCTION_CASE1:%.*]]
348 // IR-PCH-NEXT: i32 2, label [[DOTOMP_REDUCTION_CASE2:%.*]]
350 // IR-PCH: .omp.reduction.case1:
351 // IR-PCH-NEXT: [[TMP27:%.*]] = getelementptr i32, ptr [[TMP1]], i64 100
352 // IR-PCH-NEXT: [[OMP_ARRAYCPY_ISEMPTY:%.*]] = icmp eq ptr [[TMP1]], [[TMP27]]
353 // IR-PCH-NEXT: br i1 [[OMP_ARRAYCPY_ISEMPTY]], label [[OMP_ARRAYCPY_DONE18:%.*]], label [[OMP_ARRAYCPY_BODY:%.*]]
354 // IR-PCH: omp.arraycpy.body:
355 // IR-PCH-NEXT: [[OMP_ARRAYCPY_SRCELEMENTPAST:%.*]] = phi ptr [ [[SUM1]], [[DOTOMP_REDUCTION_CASE1]] ], [ [[OMP_ARRAYCPY_SRC_ELEMENT:%.*]], [[OMP_ARRAYCPY_BODY]] ]
356 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST14:%.*]] = phi ptr [ [[TMP1]], [[DOTOMP_REDUCTION_CASE1]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT16:%.*]], [[OMP_ARRAYCPY_BODY]] ]
357 // IR-PCH-NEXT: [[TMP28:%.*]] = load i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST14]], align 4
358 // IR-PCH-NEXT: [[TMP29:%.*]] = load i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], align 4
359 // IR-PCH-NEXT: [[ADD15:%.*]] = add nsw i32 [[TMP28]], [[TMP29]]
360 // IR-PCH-NEXT: store i32 [[ADD15]], ptr [[OMP_ARRAYCPY_DESTELEMENTPAST14]], align 4
361 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT16]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST14]], i32 1
362 // IR-PCH-NEXT: [[OMP_ARRAYCPY_SRC_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], i32 1
363 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DONE17:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT16]], [[TMP27]]
364 // IR-PCH-NEXT: br i1 [[OMP_ARRAYCPY_DONE17]], label [[OMP_ARRAYCPY_DONE18]], label [[OMP_ARRAYCPY_BODY]]
365 // IR-PCH: omp.arraycpy.done18:
366 // IR-PCH-NEXT: call void @__kmpc_end_reduce_nowait(ptr @[[GLOB2]], i32 [[TMP25]], ptr @.gomp_critical_user_.reduction.var)
367 // IR-PCH-NEXT: br label [[DOTOMP_REDUCTION_DEFAULT]]
368 // IR-PCH: .omp.reduction.case2:
369 // IR-PCH-NEXT: [[TMP30:%.*]] = getelementptr i32, ptr [[TMP1]], i64 100
370 // IR-PCH-NEXT: [[OMP_ARRAYCPY_ISEMPTY19:%.*]] = icmp eq ptr [[TMP1]], [[TMP30]]
371 // IR-PCH-NEXT: br i1 [[OMP_ARRAYCPY_ISEMPTY19]], label [[OMP_ARRAYCPY_DONE26:%.*]], label [[OMP_ARRAYCPY_BODY20:%.*]]
372 // IR-PCH: omp.arraycpy.body20:
373 // IR-PCH-NEXT: [[OMP_ARRAYCPY_SRCELEMENTPAST21:%.*]] = phi ptr [ [[SUM1]], [[DOTOMP_REDUCTION_CASE2]] ], [ [[OMP_ARRAYCPY_SRC_ELEMENT24:%.*]], [[OMP_ARRAYCPY_BODY20]] ]
374 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST22:%.*]] = phi ptr [ [[TMP1]], [[DOTOMP_REDUCTION_CASE2]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT23:%.*]], [[OMP_ARRAYCPY_BODY20]] ]
375 // IR-PCH-NEXT: [[TMP31:%.*]] = load i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST21]], align 4
376 // IR-PCH-NEXT: [[TMP32:%.*]] = atomicrmw add ptr [[OMP_ARRAYCPY_DESTELEMENTPAST22]], i32 [[TMP31]] monotonic, align 4
377 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT23]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST22]], i32 1
378 // IR-PCH-NEXT: [[OMP_ARRAYCPY_SRC_ELEMENT24]] = getelementptr i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST21]], i32 1
379 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DONE25:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT23]], [[TMP30]]
380 // IR-PCH-NEXT: br i1 [[OMP_ARRAYCPY_DONE25]], label [[OMP_ARRAYCPY_DONE26]], label [[OMP_ARRAYCPY_BODY20]]
381 // IR-PCH: omp.arraycpy.done26:
382 // IR-PCH-NEXT: br label [[DOTOMP_REDUCTION_DEFAULT]]
383 // IR-PCH: .omp.reduction.default:
384 // IR-PCH-NEXT: ret void
387 // IR-PCH-LABEL: define {{[^@]+}}@_Z3foov.omp_outlined.omp.reduction.reduction_func
388 // IR-PCH-SAME: (ptr noundef [[TMP0:%.*]], ptr noundef [[TMP1:%.*]]) #[[ATTR3:[0-9]+]] {
389 // IR-PCH-NEXT: entry:
390 // IR-PCH-NEXT: [[DOTADDR:%.*]] = alloca ptr, align 8
391 // IR-PCH-NEXT: [[DOTADDR1:%.*]] = alloca ptr, align 8
392 // IR-PCH-NEXT: store ptr [[TMP0]], ptr [[DOTADDR]], align 8
393 // IR-PCH-NEXT: store ptr [[TMP1]], ptr [[DOTADDR1]], align 8
394 // IR-PCH-NEXT: [[TMP2:%.*]] = load ptr, ptr [[DOTADDR]], align 8
395 // IR-PCH-NEXT: [[TMP3:%.*]] = load ptr, ptr [[DOTADDR1]], align 8
396 // IR-PCH-NEXT: [[TMP4:%.*]] = getelementptr inbounds [1 x ptr], ptr [[TMP3]], i64 0, i64 0
397 // IR-PCH-NEXT: [[TMP5:%.*]] = load ptr, ptr [[TMP4]], align 8
398 // IR-PCH-NEXT: [[TMP6:%.*]] = getelementptr inbounds [1 x ptr], ptr [[TMP2]], i64 0, i64 0
399 // IR-PCH-NEXT: [[TMP7:%.*]] = load ptr, ptr [[TMP6]], align 8
400 // IR-PCH-NEXT: [[TMP8:%.*]] = getelementptr i32, ptr [[TMP7]], i64 100
401 // IR-PCH-NEXT: [[OMP_ARRAYCPY_ISEMPTY:%.*]] = icmp eq ptr [[TMP7]], [[TMP8]]
402 // IR-PCH-NEXT: br i1 [[OMP_ARRAYCPY_ISEMPTY]], label [[OMP_ARRAYCPY_DONE2:%.*]], label [[OMP_ARRAYCPY_BODY:%.*]]
403 // IR-PCH: omp.arraycpy.body:
404 // IR-PCH-NEXT: [[OMP_ARRAYCPY_SRCELEMENTPAST:%.*]] = phi ptr [ [[TMP5]], [[ENTRY:%.*]] ], [ [[OMP_ARRAYCPY_SRC_ELEMENT:%.*]], [[OMP_ARRAYCPY_BODY]] ]
405 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DESTELEMENTPAST:%.*]] = phi ptr [ [[TMP7]], [[ENTRY]] ], [ [[OMP_ARRAYCPY_DEST_ELEMENT:%.*]], [[OMP_ARRAYCPY_BODY]] ]
406 // IR-PCH-NEXT: [[TMP9:%.*]] = load i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], align 4
407 // IR-PCH-NEXT: [[TMP10:%.*]] = load i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], align 4
408 // IR-PCH-NEXT: [[ADD:%.*]] = add nsw i32 [[TMP9]], [[TMP10]]
409 // IR-PCH-NEXT: store i32 [[ADD]], ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], align 4
410 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DEST_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_DESTELEMENTPAST]], i32 1
411 // IR-PCH-NEXT: [[OMP_ARRAYCPY_SRC_ELEMENT]] = getelementptr i32, ptr [[OMP_ARRAYCPY_SRCELEMENTPAST]], i32 1
412 // IR-PCH-NEXT: [[OMP_ARRAYCPY_DONE:%.*]] = icmp eq ptr [[OMP_ARRAYCPY_DEST_ELEMENT]], [[TMP8]]
413 // IR-PCH-NEXT: br i1 [[OMP_ARRAYCPY_DONE]], label [[OMP_ARRAYCPY_DONE2]], label [[OMP_ARRAYCPY_BODY]]
414 // IR-PCH: omp.arraycpy.done2:
415 // IR-PCH-NEXT: ret void