[all-commits] [llvm/llvm-project] e166c6: [flang][OpenMP] lower simple array reductions
Tom Eccles via All-commits
all-commits at lists.llvm.org
Wed Mar 20 03:34:36 PDT 2024
Branch: refs/heads/users/tblah/omp_array_reduction_6
Home: https://github.com/llvm/llvm-project
Commit: e166c69ca9c27a774bada5538190bf8f94cef6d4
https://github.com/llvm/llvm-project/commit/e166c69ca9c27a774bada5538190bf8f94cef6d4
Author: Tom Eccles <tom.eccles at arm.com>
Date: 2024-03-20 (Wed, 20 Mar 2024)
Changed paths:
M flang/lib/Lower/OpenMP/ReductionProcessor.cpp
M flang/lib/Lower/OpenMP/ReductionProcessor.h
R flang/test/Lower/OpenMP/Todo/reduction-arrays.f90
A flang/test/Lower/OpenMP/parallel-reduction-array.f90
A flang/test/Lower/OpenMP/wsloop-reduction-array.f90
Log Message:
-----------
[flang][OpenMP] lower simple array reductions
This has been tested with arrays with compile-time constant bounds.
Allocatable arrays and arrays with non-constant bounds are not yet
supported. User-defined reduction functions are also not yet supported.
The design is intended to work for arrays with non-constant bounds too
without a lot of extra work (mostly there are bugs in OpenMPIRBuilder I
haven't fixed yet).
We need some way to get these runtime bounds into the reduction init and
combiner regions. To keep things simple for now I opted to always box the
array arguments so the box can be passed as one argument and the lower
bounds and extents read from the box. This has the disadvantage of
resulting in fir.box_dim operations inside of the critical section. If
these prove to be a performance issue, we could follow OpenACC reading
box lower bounds and extents before the reduction and passing them as
block arguments to the reduction init and combiner regions. I would
prefer to keep things simple for now.
Note: this implementation only works when the HLFIR lowering is used. I
don't think it is worth supporting FIR-only lowering because the plan is
for that to be removed soon.
Commit: d0b6f12882e5778fcaa47582f24d9d9613ed8e36
https://github.com/llvm/llvm-project/commit/d0b6f12882e5778fcaa47582f24d9d9613ed8e36
Author: Tom Eccles <tom.eccles at arm.com>
Date: 2024-03-20 (Wed, 20 Mar 2024)
Changed paths:
M flang/lib/Lower/OpenMP/ReductionProcessor.cpp
Log Message:
-----------
Update TODO message
Commit: e6155a5ed6d9cbcf79109a753c3c0b55c0a32e33
https://github.com/llvm/llvm-project/commit/e6155a5ed6d9cbcf79109a753c3c0b55c0a32e33
Author: Tom Eccles <tom.eccles at arm.com>
Date: 2024-03-20 (Wed, 20 Mar 2024)
Changed paths:
M flang/lib/Lower/OpenMP/ReductionProcessor.cpp
Log Message:
-----------
Add TODO for stack allocations inside of a loop
Commit: 209cd389ff762e4aaece5b580ab7a2a5c1ab2472
https://github.com/llvm/llvm-project/commit/209cd389ff762e4aaece5b580ab7a2a5c1ab2472
Author: Tom Eccles <tom.eccles at arm.com>
Date: 2024-03-20 (Wed, 20 Mar 2024)
Changed paths:
M flang/include/flang/Optimizer/Builder/HLFIRTools.h
M flang/lib/Lower/OpenMP/ReductionProcessor.cpp
M flang/lib/Optimizer/Builder/HLFIRTools.cpp
M flang/test/Lower/OpenMP/parallel-reduction-array.f90
M flang/test/Lower/OpenMP/wsloop-reduction-array.f90
Log Message:
-----------
Move createStackTempFromMold into a function
Commit: e30d18a03439fe4580820c094ee721f7dba63792
https://github.com/llvm/llvm-project/commit/e30d18a03439fe4580820c094ee721f7dba63792
Author: Tom Eccles <tom.eccles at arm.com>
Date: 2024-03-20 (Wed, 20 Mar 2024)
Changed paths:
A flang/test/Lower/OpenMP/parallel-reduction-array2.f90
A flang/test/Lower/OpenMP/wsloop-reduction-array2.f90
Log Message:
-----------
Add more tests
Compare: https://github.com/llvm/llvm-project/compare/8eaefa5c7f0c...e30d18a03439
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list