[llvm-branch-commits] [flang] [mlir] [mlir][OpenMP][flang] make private variable allocation implicit in omp.private (PR #124019)
Tom Eccles via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Fri Jan 24 03:24:16 PST 2025
================
@@ -55,15 +55,19 @@ class MapsForPrivatizedSymbolsPass
std::underlying_type_t<llvm::omp::OpenMPOffloadMappingFlags>>(
llvm::omp::OpenMPOffloadMappingFlags::OMP_MAP_TO);
Operation *definingOp = var.getDefiningOp();
- auto declOp = llvm::dyn_cast_or_null<hlfir::DeclareOp>(definingOp);
- assert(declOp &&
- "Expected defining Op of privatized var to be hlfir.declare");
+ assert(definingOp &&
+ "Privatizing a block argument without any hlfir.declare");
----------------
tblah wrote:
I was nervous to make any functional change to the target stuff because I don't know how to test it. The previous implementation also wouldn't have worked for block arguments.
I can fix this if somebody at AMD is willing to test `omp target` for me?
https://github.com/llvm/llvm-project/pull/124019
More information about the llvm-branch-commits
mailing list