[all-commits] [llvm/llvm-project] e8039a: [OpenMP] Identify GPU kernels (aka. OpenMP target ...
Johannes Doerfert via All-commits
all-commits at lists.llvm.org
Fri Jul 10 23:50:20 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: e8039ad4def0c4a2499cfbaba38bcc8ef48dee92
https://github.com/llvm/llvm-project/commit/e8039ad4def0c4a2499cfbaba38bcc8ef48dee92
Author: Johannes Doerfert <johannes at jdoerfert.de>
Date: 2020-07-11 (Sat, 11 Jul 2020)
Changed paths:
M llvm/include/llvm/Transforms/IPO/OpenMPOpt.h
M llvm/lib/Transforms/IPO/OpenMPOpt.cpp
A llvm/test/Transforms/OpenMP/gpu_kernel_detection_remarks.ll
Log Message:
-----------
[OpenMP] Identify GPU kernels (aka. OpenMP target regions)
We now identify GPU kernels, that is entry points into the GPU code.
These kernels (can) correspond to OpenMP target regions. With this patch
we identify and on request print them via remarks.
Reviewed By: JonChesterfield
Differential Revision: https://reviews.llvm.org/D83269
Commit: 624d34afff5de099a6f84e678c81055556c3d42d
https://github.com/llvm/llvm-project/commit/624d34afff5de099a6f84e678c81055556c3d42d
Author: Johannes Doerfert <johannes at jdoerfert.de>
Date: 2020-07-11 (Sat, 11 Jul 2020)
Changed paths:
M llvm/lib/Transforms/IPO/OpenMPOpt.cpp
Log Message:
-----------
[OpenMP] Compute a proper module slice for the CGSCCC pass
The module slice describes which functions we can analyze and transform
while working on an SCC as part of the CGSCC OpenMPOpt pass. So far, we
simply restricted it to the SCC. In a follow up we will need to have a
bigger scope which is why this patch introduces a proper identification
of the module slice. In short, everything that has a transitive
reference to a function in the SCC or is transitively referenced by one
is fair game.
Reviewed By: sstefan1
Differential Revision: https://reviews.llvm.org/D83270
Commit: 5b0581aedc2252481462970503d1085dc27e65eb
https://github.com/llvm/llvm-project/commit/5b0581aedc2252481462970503d1085dc27e65eb
Author: Johannes Doerfert <johannes at jdoerfert.de>
Date: 2020-07-11 (Sat, 11 Jul 2020)
Changed paths:
M llvm/lib/Transforms/IPO/OpenMPOpt.cpp
A llvm/test/Transforms/OpenMP/gpu_state_machine_function_ptr_replacement.ll
Log Message:
-----------
[OpenMP] Replace function pointer uses in GPU state machine
In non-SPMD mode we create a state machine like code to identify the
parallel region the GPU worker threads should execute next. The
identification uses the parallel region function pointer as that allows
it to work even if the kernel (=target region) and the parallel region
are in separate TUs. However, taking the address of a function comes
with various downsides. With this patch we will identify the most common
situation and replace the function pointer use with a dummy global
symbol (for identification purposes only). That means, if the parallel
region is only called from a single target region (or kernel), we do not
use the function pointer of the parallel region to identify it but a new
global symbol.
Fixes PR46450.
Reviewed By: JonChesterfield
Differential Revision: https://reviews.llvm.org/D83271
Compare: https://github.com/llvm/llvm-project/compare/54bd3751ceeb...5b0581aedc22
More information about the All-commits
mailing list