[all-commits] [llvm/llvm-project] b34c5d: [flang][OpenMP] Lower target in_reduction for host...
Sairudra More via All-commits
all-commits at lists.llvm.org
Thu Jul 9 20:52:55 PDT 2026
Branch: refs/heads/users/saieiei/target-in-reduction
Home: https://github.com/llvm/llvm-project
Commit: b34c5df5b8785da1cad68a4e7f54bdd2d895f04b
https://github.com/llvm/llvm-project/commit/b34c5df5b8785da1cad68a4e7f54bdd2d895f04b
Author: Sairudra More <sairudra60 at gmail.com>
Date: 2026-07-09 (Thu, 09 Jul 2026)
Changed paths:
M flang/lib/Lower/OpenMP/OpenMP.cpp
A flang/test/Integration/OpenMP/target-inreduction-llvmir.f90
A flang/test/Lower/OpenMP/Todo/target-inreduction-common.f90
A flang/test/Lower/OpenMP/Todo/target-inreduction-equivalence.f90
A flang/test/Lower/OpenMP/Todo/target-inreduction-firstprivate.f90
R flang/test/Lower/OpenMP/Todo/target-inreduction.f90
A flang/test/Lower/OpenMP/target-inreduction-unused.f90
A flang/test/Lower/OpenMP/target-inreduction.f90
M llvm/include/llvm/Frontend/OpenMP/OMPIRBuilder.h
M llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp
M mlir/include/mlir/Dialect/OpenMP/OpenMPClauses.td
M mlir/include/mlir/Dialect/OpenMP/OpenMPOps.td
M mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
M mlir/lib/Target/LLVMIR/Dialect/OpenMP/OpenMPToLLVMIRTranslation.cpp
M mlir/test/Dialect/OpenMP/host-op-filtering.mlir
M mlir/test/Dialect/OpenMP/invalid.mlir
A mlir/test/Target/LLVMIR/openmp-target-in-reduction-device.mlir
A mlir/test/Target/LLVMIR/openmp-target-in-reduction-multi.mlir
A mlir/test/Target/LLVMIR/openmp-target-in-reduction.mlir
M mlir/test/Target/LLVMIR/openmp-todo.mlir
Log Message:
-----------
[flang][OpenMP] Lower target in_reduction for host fallback
Enable host-fallback lowering for target in_reduction in Flang and MLIR OpenMP translation.
Model target in_reduction through the matching map entry, force address-preserving implicit mapping for Flang in_reduction list items, and emit the host-side task-reduction lookup with __kmpc_task_reduction_get_th_data. The runtime entry point takes and returns a generic, default-address-space pointer, so normalize a non-default-address-space captured pointer to the generic address space before the call and cast the returned private pointer back to the map block argument's address space, mirroring the in_reduction handling on omp.taskloop. On the target device, in_reduction is handled as a regular map(tofrom) variable. The byref modifier, two-argument initializers, cleanup regions, and the remaining Flang COMMON/EQUIVALENCE/privatized-variable cases continue to be diagnosed.
Add Flang lowering, MLIR verifier/translation, and LLVM IR tests for the supported host-fallback path, including a non-default-address-space case, and the remaining unsupported cases.
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