Skip to content

Commit d4cf5c9

Browse files
committed
[flang][OpenMP] Extend delayed privatization for omp.simd
Adds support for delayed privatization for `simd` directives. This PR includes PFT down to LLVM IR lowering.
1 parent d6b6598 commit d4cf5c9

File tree

9 files changed

+182
-62
lines changed

9 files changed

+182
-62
lines changed

flang/lib/Lower/OpenMP/OpenMP.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -2144,19 +2144,19 @@ static void genStandaloneSimd(lower::AbstractConverter &converter,
21442144
genSimdClauses(converter, semaCtx, item->clauses, loc, simdClauseOps,
21452145
simdReductionSyms);
21462146

2147-
// TODO: Support delayed privatization.
21482147
DataSharingProcessor dsp(converter, semaCtx, item->clauses, eval,
21492148
/*shouldCollectPreDeterminedSymbols=*/true,
2150-
/*useDelayedPrivatization=*/false, symTable);
2151-
dsp.processStep1();
2149+
enableDelayedPrivatization, symTable);
2150+
dsp.processStep1(&simdClauseOps);
21522151

21532152
mlir::omp::LoopNestOperands loopNestClauseOps;
21542153
llvm::SmallVector<const semantics::Symbol *> iv;
21552154
genLoopNestClauses(converter, semaCtx, eval, item->clauses, loc,
21562155
loopNestClauseOps, iv);
21572156

21582157
EntryBlockArgs simdArgs;
2159-
// TODO: Add private syms and vars.
2158+
simdArgs.priv.syms = dsp.getDelayedPrivSymbols();
2159+
simdArgs.priv.vars = simdClauseOps.privateVars;
21602160
simdArgs.reduction.syms = simdReductionSyms;
21612161
simdArgs.reduction.vars = simdClauseOps.reductionVars;
21622162
auto simdOp =

flang/test/Lower/OpenMP/order-clause.f90

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,15 @@
44

55
!CHECK-LABEL: func.func @_QPsimd_order() {
66
subroutine simd_order
7-
!CHECK: omp.simd order(reproducible:concurrent) {
7+
!CHECK: omp.simd order(reproducible:concurrent) private({{.*}}) {
88
!$omp simd order(concurrent)
99
do i = 1, 10
1010
end do
11-
!CHECK: omp.simd order(reproducible:concurrent) {
11+
!CHECK: omp.simd order(reproducible:concurrent) private({{.*}}) {
1212
!$omp simd order(reproducible:concurrent)
1313
do i = 1, 10
1414
end do
15-
!CHECK: omp.simd order(unconstrained:concurrent) {
15+
!CHECK: omp.simd order(unconstrained:concurrent) private({{.*}}) {
1616
!$omp simd order(unconstrained:concurrent)
1717
do i = 1, 10
1818
end do

flang/test/Lower/OpenMP/parallel-private-clause.f90

+20-12
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,23 @@
55
! RUN: bbc --use-desc-for-alloc=false -fopenmp -emit-hlfir %s -o - \
66
! RUN: | FileCheck %s --check-prefix=FIRDialect
77

8+
! FIRDialect: omp.private {type = private} @_QFsimd_loop_1Er_private_ref_box_heap_f32 {{.*}} alloc {
9+
! FIRDialect: [[R:%.*]] = fir.alloca !fir.box<!fir.heap<f32>> {bindc_name = "r", pinned, uniq_name = "{{.*}}Er"}
10+
! FIRDialect: fir.store {{%.*}} to [[R]] : !fir.ref<!fir.box<!fir.heap<f32>>>
11+
! FIRDialect: fir.store {{%.*}} to [[R]] : !fir.ref<!fir.box<!fir.heap<f32>>>
12+
! FIRDialect: [[R_DECL:%.*]]:2 = hlfir.declare [[R]] {fortran_attrs = #fir.var_attrs<allocatable>, uniq_name = "{{.*}}r"} : (!fir.ref<!fir.box<!fir.heap<f32>>>) -> (!fir.ref<!fir.box<!fir.heap<f32>>>, !fir.ref<!fir.box<!fir.heap<f32>>>)
13+
! FIRDialect: omp.yield([[R_DECL]]#0 : !fir.ref<!fir.box<!fir.heap<f32>>>)
14+
! FIRDialect: } dealloc {
15+
! FIRDialect: ^bb0([[R_DECL:%.*]]: !fir.ref<!fir.box<!fir.heap<f32>>>):
16+
! FIRDialect: {{%.*}} = fir.load [[R_DECL]] : !fir.ref<!fir.box<!fir.heap<f32>>>
17+
! FIRDialect: fir.if {{%.*}} {
18+
! FIRDialect: [[LD:%.*]] = fir.load [[R_DECL]] : !fir.ref<!fir.box<!fir.heap<f32>>>
19+
! FIRDialect: [[AD:%.*]] = fir.box_addr [[LD]] : (!fir.box<!fir.heap<f32>>) -> !fir.heap<f32>
20+
! FIRDialect: fir.freemem [[AD]] : !fir.heap<f32>
21+
! FIRDialect: fir.store {{%.*}} to [[R_DECL]] : !fir.ref<!fir.box<!fir.heap<f32>>>
22+
! FIRDialect: omp.yield
23+
! FIRDialect: }
24+
825
!FIRDialect: omp.private {type = private} @[[DERIVED_PRIVATIZER:_QFprivate_clause_derived_typeEt_private_ref_rec__QFprivate_clause_derived_typeTmy_type]] : !fir.ref<!fir.type<_QFprivate_clause_derived_typeTmy_type{t_i:i32,t_arr:!fir.array<5xi32>}>> alloc {
926
!FIRDialect: ^bb0(%{{.*}}: !fir.ref<!fir.type<_QFprivate_clause_derived_typeTmy_type{t_i:i32,t_arr:!fir.array<5xi32>}>>):
1027
!FIRDialect: %[[PRIV_ALLOC:.*]] = fir.alloca !fir.type<_QFprivate_clause_derived_typeTmy_type{t_i:i32,t_arr:!fir.array<5xi32>}> {bindc_name = "t", pinned, uniq_name = "_QFprivate_clause_derived_typeEt"}
@@ -246,7 +263,6 @@ subroutine parallel_pointer()
246263
!$omp end parallel
247264
end subroutine parallel_pointer
248265

249-
250266
!FIRDialect-LABEL: func @_QPsimple_loop_1()
251267
subroutine simple_loop_1
252268
integer :: i
@@ -354,20 +370,17 @@ subroutine simple_loop_3
354370
! FIRDialect: omp.terminator
355371
end subroutine
356372

373+
357374
!CHECK-LABEL: func @_QPsimd_loop_1()
358375
subroutine simd_loop_1
359376
integer :: i
360377
real, allocatable :: r;
361-
! FIRDialect: [[R:%.*]] = fir.alloca !fir.box<!fir.heap<f32>> {bindc_name = "r", pinned, uniq_name = "{{.*}}Er"}
362-
! FIRDialect: fir.store {{%.*}} to [[R]] : !fir.ref<!fir.box<!fir.heap<f32>>>
363-
! FIRDialect: fir.store {{%.*}} to [[R]] : !fir.ref<!fir.box<!fir.heap<f32>>>
364-
! FIRDialect: [[R_DECL:%.*]]:2 = hlfir.declare [[R]] {fortran_attrs = #fir.var_attrs<allocatable>, uniq_name = "{{.*}}r"} : (!fir.ref<!fir.box<!fir.heap<f32>>>) -> (!fir.ref<!fir.box<!fir.heap<f32>>>, !fir.ref<!fir.box<!fir.heap<f32>>>)
365378

366379
! FIRDialect: %[[LB:.*]] = arith.constant 1 : i32
367380
! FIRDialect: %[[UB:.*]] = arith.constant 9 : i32
368381
! FIRDialect: %[[STEP:.*]] = arith.constant 1 : i32
369382

370-
! FIRDialect: omp.simd {
383+
! FIRDialect: omp.simd private({{.*}}) {
371384
! FIRDialect-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
372385
!$OMP SIMD PRIVATE(r)
373386
do i=1, 9
@@ -378,10 +391,5 @@ subroutine simd_loop_1
378391
end do
379392
!$OMP END SIMD
380393
! FIRDialect: omp.yield
381-
! FIRDialect: {{%.*}} = fir.load [[R_DECL]]#0 : !fir.ref<!fir.box<!fir.heap<f32>>>
382-
! FIRDialect: fir.if {{%.*}} {
383-
! FIRDialect: [[LD:%.*]] = fir.load [[R_DECL]]#0 : !fir.ref<!fir.box<!fir.heap<f32>>>
384-
! FIRDialect: [[AD:%.*]] = fir.box_addr [[LD]] : (!fir.box<!fir.heap<f32>>) -> !fir.heap<f32>
385-
! FIRDialect: fir.freemem [[AD]] : !fir.heap<f32>
386-
! FIRDialect: fir.store {{%.*}} to [[R_DECL]]#0 : !fir.ref<!fir.box<!fir.heap<f32>>>
394+
387395
end subroutine

flang/test/Lower/OpenMP/simd.f90

+13-15
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ subroutine simd
1313
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
1414
! CHECK-NEXT: %[[UB:.*]] = arith.constant 9 : i32
1515
! CHECK-NEXT: %[[STEP:.*]] = arith.constant 1 : i32
16-
! CHECK-NEXT: omp.simd {
16+
! CHECK-NEXT: omp.simd private({{.*}}) {
1717
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
1818
do i=1, 9
1919
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -33,7 +33,7 @@ subroutine simd_with_if_clause(n, threshold)
3333
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
3434
! CHECK: %[[UB:.*]] = fir.load %[[ARG_N]]#0
3535
! CHECK: %[[STEP:.*]] = arith.constant 1 : i32
36-
! CHECK: omp.simd if(%[[COND:.*]]) {
36+
! CHECK: omp.simd if(%[[COND:.*]]) private({{.*}}) {
3737
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
3838
do i = 1, n
3939
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -52,7 +52,7 @@ subroutine simd_with_simdlen_clause(n, threshold)
5252
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
5353
! CHECK: %[[UB:.*]] = fir.load %[[ARG_N]]#0
5454
! CHECK: %[[STEP:.*]] = arith.constant 1 : i32
55-
! CHECK: omp.simd simdlen(2) {
55+
! CHECK: omp.simd simdlen(2) private({{.*}}) {
5656
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
5757
do i = 1, n
5858
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -72,7 +72,7 @@ subroutine simd_with_simdlen_clause_from_param(n, threshold)
7272
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
7373
! CHECK: %[[UB:.*]] = fir.load %[[ARG_N]]#0
7474
! CHECK: %[[STEP:.*]] = arith.constant 1 : i32
75-
! CHECK: omp.simd simdlen(2) {
75+
! CHECK: omp.simd simdlen(2) private({{.*}}) {
7676
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
7777
do i = 1, n
7878
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -92,7 +92,7 @@ subroutine simd_with_simdlen_clause_from_expr_from_param(n, threshold)
9292
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
9393
! CHECK: %[[UB:.*]] = fir.load %[[ARG_N]]#0
9494
! CHECK: %[[STEP:.*]] = arith.constant 1 : i32
95-
! CHECK: omp.simd simdlen(6) {
95+
! CHECK: omp.simd simdlen(6) private({{.*}}) {
9696
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
9797
do i = 1, n
9898
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -111,7 +111,7 @@ subroutine simd_with_safelen_clause(n, threshold)
111111
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
112112
! CHECK: %[[UB:.*]] = fir.load %[[ARG_N]]#0
113113
! CHECK: %[[STEP:.*]] = arith.constant 1 : i32
114-
! CHECK: omp.simd safelen(2) {
114+
! CHECK: omp.simd safelen(2) private({{.*}}) {
115115
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
116116
do i = 1, n
117117
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -131,7 +131,7 @@ subroutine simd_with_safelen_clause_from_expr_from_param(n, threshold)
131131
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
132132
! CHECK: %[[UB:.*]] = fir.load %[[ARG_N]]#0
133133
! CHECK: %[[STEP:.*]] = arith.constant 1 : i32
134-
! CHECK: omp.simd safelen(6) {
134+
! CHECK: omp.simd safelen(6) private({{.*}}) {
135135
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
136136
do i = 1, n
137137
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -150,7 +150,7 @@ subroutine simd_with_simdlen_safelen_clause(n, threshold)
150150
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
151151
! CHECK: %[[UB:.*]] = fir.load %[[ARG_N]]#0
152152
! CHECK: %[[STEP:.*]] = arith.constant 1 : i32
153-
! CHECK: omp.simd safelen(2) simdlen(1) {
153+
! CHECK: omp.simd safelen(2) simdlen(1) private({{.*}}) {
154154
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
155155
do i = 1, n
156156
! CHECK: fir.store %[[I]] to %[[LOCAL:.*]]#1 : !fir.ref<i32>
@@ -171,7 +171,7 @@ subroutine simd_with_collapse_clause(n)
171171
! CHECK: %[[LOWER_J:.*]] = arith.constant 1 : i32
172172
! CHECK: %[[UPPER_J:.*]] = fir.load %[[PARAM_ARG:.*]] : !fir.ref<i32>
173173
! CHECK: %[[STEP_J:.*]] = arith.constant 1 : i32
174-
! CHECK: omp.simd {
174+
! CHECK: omp.simd private({{.*}}) {
175175
! CHECK-NEXT: omp.loop_nest (%[[ARG_0:.*]], %[[ARG_1:.*]]) : i32 = (
176176
! CHECK-SAME: %[[LOWER_I]], %[[LOWER_J]]) to (
177177
! CHECK-SAME: %[[UPPER_I]], %[[UPPER_J]]) inclusive step (
@@ -235,7 +235,7 @@ subroutine simd_with_nontemporal_clause(n)
235235
!CHECK: %[[LB:.*]] = arith.constant 1 : i32
236236
!CHECK: %[[UB:.*]] = fir.load %{{.*}}#0 : !fir.ref<i32>
237237
!CHECK: %[[STEP:.*]] = arith.constant 1 : i32
238-
!CHECK: omp.simd nontemporal(%[[A_DECL]]#1, %[[C_DECL]]#1 : !fir.ref<i32>, !fir.ref<i32>) {
238+
!CHECK: omp.simd nontemporal(%[[A_DECL]]#1, %[[C_DECL]]#1 : !fir.ref<i32>, !fir.ref<i32>) private({{.*}}) {
239239
!CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
240240
!$OMP SIMD NONTEMPORAL(A, C)
241241
do i = 1, n
@@ -249,16 +249,14 @@ subroutine lastprivate_with_simd
249249

250250
!CHECK: %[[VAR_SUM:.*]] = fir.alloca f32 {bindc_name = "sum", uniq_name = "_QFlastprivate_with_simdEsum"}
251251
!CHECK: %[[VAR_SUM_DECLARE:.*]]:2 = hlfir.declare %[[VAR_SUM]] {{.*}}
252-
!CHECK: %[[VAR_SUM_PINNED:.*]] = fir.alloca f32 {bindc_name = "sum", pinned, uniq_name = "_QFlastprivate_with_simdEsum"}
253-
!CHECK: %[[VAR_SUM_PINNED_DECLARE:.*]]:2 = hlfir.declare %[[VAR_SUM_PINNED]] {{.*}}
254-
255252
implicit none
256253
integer :: i
257254
real :: sum
258255

259256

260-
!CHECK: omp.simd {
257+
!CHECK: omp.simd private(@_QFlastprivate_with_simdEsum_private_ref_f32 %[[VAR_SUM_DECLARE]]#0 -> %[[VAR_SUM_PINNED:.*]], @{{.*}}) {
261258
!CHECK: omp.loop_nest (%[[ARG:.*]]) : i32 = ({{.*}} to ({{.*}}) inclusive step ({{.*}}) {
259+
!CHECK: %[[VAR_SUM_PINNED_DECLARE:.*]]:2 = hlfir.declare %[[VAR_SUM_PINNED]] {{.*}}
262260
!CHECK: %[[ADD_RESULT:.*]] = arith.addi {{.*}}
263261
!CHECK: %[[ADD_RESULT_CONVERT:.*]] = fir.convert %[[ADD_RESULT]] : (i32) -> f32
264262
!CHECK: hlfir.assign %[[ADD_RESULT_CONVERT]] to %[[VAR_SUM_PINNED_DECLARE]]#0 : f32, !fir.ref<f32>
@@ -283,7 +281,7 @@ subroutine simd_with_reduction_clause
283281
! CHECK: %[[LB:.*]] = arith.constant 1 : i32
284282
! CHECK-NEXT: %[[UB:.*]] = arith.constant 9 : i32
285283
! CHECK-NEXT: %[[STEP:.*]] = arith.constant 1 : i32
286-
! CHECK-NEXT: omp.simd reduction(@[[REDUCER]] %[[X:.*]]#0 -> %[[X_RED:.*]] : !fir.ref<i32>) {
284+
! CHECK-NEXT: omp.simd private({{.*}}) reduction(@[[REDUCER]] %[[X:.*]]#0 -> %[[X_RED:.*]] : !fir.ref<i32>) {
287285
! CHECK-NEXT: omp.loop_nest (%[[I:.*]]) : i32 = (%[[LB]]) to (%[[UB]]) inclusive step (%[[STEP]]) {
288286
!$omp simd reduction(+:x)
289287
do i=1, 9

llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp

+1-6
Original file line numberDiff line numberDiff line change
@@ -5203,12 +5203,7 @@ void OpenMPIRBuilder::createIfVersion(CanonicalLoopInfo *CanonicalLoop,
52035203
Function *F = CanonicalLoop->getFunction();
52045204

52055205
// Define where if branch should be inserted
5206-
Instruction *SplitBefore;
5207-
if (Instruction::classof(IfCond)) {
5208-
SplitBefore = dyn_cast<Instruction>(IfCond);
5209-
} else {
5210-
SplitBefore = CanonicalLoop->getPreheader()->getTerminator();
5211-
}
5206+
Instruction *SplitBefore = CanonicalLoop->getPreheader()->getTerminator();
52125207

52135208
// TODO: We should not rely on pass manager. Currently we use pass manager
52145209
// only for getting llvm::Loop which corresponds to given CanonicalLoopInfo

mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -2116,7 +2116,7 @@ void SimdOp::build(OpBuilder &builder, OperationState &state,
21162116
makeArrayAttr(ctx, clauses.alignments), clauses.ifExpr,
21172117
/*linear_vars=*/{}, /*linear_step_vars=*/{},
21182118
clauses.nontemporalVars, clauses.order, clauses.orderMod,
2119-
/*private_vars=*/{}, /*private_syms=*/nullptr,
2119+
clauses.privateVars, makeArrayAttr(ctx, clauses.privateSyms),
21202120
clauses.reductionVars,
21212121
makeDenseBoolArrayAttr(ctx, clauses.reductionByref),
21222122
makeArrayAttr(ctx, clauses.reductionSyms), clauses.safelen,

mlir/lib/Target/LLVMIR/Dialect/OpenMP/OpenMPToLLVMIRTranslation.cpp

+23-2
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,6 @@ static LogicalResult checkImplementationStatus(Operation &op) {
273273
.Case([&](omp::SimdOp op) {
274274
checkLinear(op, result);
275275
checkNontemporal(op, result);
276-
checkPrivate(op, result);
277276
checkReduction(op, result);
278277
})
279278
.Case<omp::AtomicReadOp, omp::AtomicWriteOp, omp::AtomicUpdateOp,
@@ -2230,8 +2229,28 @@ convertOmpSimd(Operation &opInst, llvm::IRBuilderBase &builder,
22302229
if (failed(checkImplementationStatus(opInst)))
22312230
return failure();
22322231

2232+
MutableArrayRef<BlockArgument> privateBlockArgs =
2233+
cast<omp::BlockArgOpenMPOpInterface>(*simdOp).getPrivateBlockArgs();
2234+
SmallVector<mlir::Value> mlirPrivateVars;
2235+
SmallVector<llvm::Value *> llvmPrivateVars;
2236+
SmallVector<omp::PrivateClauseOp> privateDecls;
2237+
mlirPrivateVars.reserve(privateBlockArgs.size());
2238+
llvmPrivateVars.reserve(privateBlockArgs.size());
2239+
collectPrivatizationDecls(simdOp, privateDecls);
2240+
2241+
for (mlir::Value privateVar : simdOp.getPrivateVars())
2242+
mlirPrivateVars.push_back(privateVar);
2243+
2244+
llvm::OpenMPIRBuilder::InsertPointTy allocaIP =
2245+
findAllocaInsertPoint(builder, moduleTranslation);
22332246
llvm::OpenMPIRBuilder::LocationDescription ompLoc(builder);
22342247

2248+
llvm::Expected<llvm::BasicBlock *> afterAllocas = allocatePrivateVars(
2249+
builder, moduleTranslation, privateBlockArgs, privateDecls,
2250+
mlirPrivateVars, llvmPrivateVars, allocaIP);
2251+
if (handleError(afterAllocas, opInst).failed())
2252+
return failure();
2253+
22352254
// Generator of the canonical loop body.
22362255
SmallVector<llvm::CanonicalLoopInfo *> loopInfos;
22372256
SmallVector<llvm::OpenMPIRBuilder::InsertPointTy> bodyInsertPoints;
@@ -2331,7 +2350,9 @@ convertOmpSimd(Operation &opInst, llvm::IRBuilderBase &builder,
23312350
order, simdlen, safelen);
23322351

23332352
builder.restoreIP(afterIP);
2334-
return success();
2353+
2354+
return cleanupPrivateVars(builder, moduleTranslation, simdOp.getLoc(),
2355+
llvmPrivateVars, privateDecls);
23352356
}
23362357

23372358
/// Convert an Atomic Ordering attribute to llvm::AtomicOrdering.

0 commit comments

Comments
 (0)