[Openmp-commits] [PATCH] D142569: [OpenMP] Introduce kernel environment
Johannes Doerfert via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Wed Feb 22 09:12:51 PST 2023
jdoerfert added inline comments.
================
Comment at: openmp/libomptarget/plugins-nextgen/common/PluginInterface/PluginInterface.cpp:583
+ if (!KernelEnvOrError)
+ return KernelEnvOrError.takeError();
+
----------------
tianshilei1992 wrote:
> jdoerfert wrote:
> > We used to default to SPMD w/o a _exec_mode. Unsure if this will cause problems. I am inclined to allow missing _kernel_env as well and use SPMD then.
> Now we need the global variable to call `target_init` at runtime, so missing it sounds like a bug. I'm not sure if we would optimize the symbol out, but I kinda doubt it.
Missing used to mean, and does, that it's not a "target region" kernel. So it might be a con/de-structor or a kernel coming from elsewhere, e.g., CUDA. We should continue that behavior I think.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D142569/new/
https://reviews.llvm.org/D142569
More information about the Openmp-commits
mailing list