Skip to content

Commit 5647d02

Browse files
committed
[flang] Enable delayed localization by default for do concurrent
1 parent 8c8d15a commit 5647d02

File tree

6 files changed

+6
-10
lines changed

6 files changed

+6
-10
lines changed

flang/lib/Lower/Bridge.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2031,11 +2031,7 @@ class FirConverter : public Fortran::lower::AbstractConverter {
20312031
fir::LocalitySpecifierOperands privateClauseOps;
20322032
auto doConcurrentLoopOp =
20332033
mlir::dyn_cast_if_present<fir::DoConcurrentLoopOp>(info.loopOp);
2034-
// TODO Promote to using `enableDelayedPrivatization` (which is enabled by
2035-
// default unlike the staging flag) once the implementation of this is more
2036-
// complete.
2037-
bool useDelayedPriv =
2038-
enableDelayedPrivatizationStaging && doConcurrentLoopOp;
2034+
bool useDelayedPriv = enableDelayedPrivatization && doConcurrentLoopOp;
20392035
llvm::SetVector<const Fortran::semantics::Symbol *> allPrivatizedSymbols;
20402036
llvm::SmallSet<const Fortran::semantics::Symbol *, 16> mightHaveReadHostSym;
20412037

flang/test/Lower/do_concurrent_delayed_locality.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
! RUN: %flang_fc1 -emit-hlfir -mmlir --enable-delayed-privatization-staging=true -o - %s | FileCheck %s
1+
! RUN: %flang_fc1 -emit-hlfir -o - %s | FileCheck %s
22

33
subroutine do_concurrent_with_locality_specs
44
implicit none

flang/test/Lower/do_concurrent_local_assoc_entity.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
! RUN: %flang_fc1 -emit-hlfir -mmlir --enable-delayed-privatization-staging=true -o - %s | FileCheck %s
1+
! RUN: %flang_fc1 -emit-hlfir -o - %s | FileCheck %s
22

33
subroutine local_assoc
44
implicit none

flang/test/Lower/do_concurrent_local_default_init.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
! Test default initialization of DO CONCURRENT LOCAL() entities.
2-
! RUN: bbc -emit-hlfir --enable-delayed-privatization-staging=true -I nowhere -o - %s | FileCheck %s
2+
! RUN: bbc -emit-hlfir -I nowhere -o - %s | FileCheck %s
33

44
subroutine test_ptr(p)
55
interface

flang/test/Lower/loops.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
! RUN: bbc -emit-fir -hlfir=false -o - %s | FileCheck %s
1+
! RUN: bbc -emit-fir -hlfir=false --enable-delayed-privatization=false -o - %s | FileCheck %s
22

33
! CHECK-LABEL: loop_test
44
subroutine loop_test

flang/test/Lower/loops3.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
! Test do concurrent reduction
2-
! RUN: bbc -emit-fir -hlfir=false -o - %s | FileCheck %s
2+
! RUN: bbc -emit-fir -hlfir=false --enable-delayed-privatization=false -o - %s | FileCheck %s
33

44
! CHECK-LABEL: loop_test
55
subroutine loop_test

0 commit comments

Comments
 (0)