[Openmp-commits] [clang] [llvm] [openmp] [OpenMP] Change build of OpenMP device runtime to be a separate runtime (PR #136729)
Joseph Huber via Openmp-commits
openmp-commits at lists.llvm.org
Wed Apr 23 06:25:26 PDT 2025
jhuber6 wrote:
> I think using the LLVM_ENABLE_RUNTIMES-machanism is a great idea. Regarding the move back to `openmp/device`, I don't really have an opinion. However, there are some arguments to make:
>
> 1. The same arguments apply to `libomptarget` as well
>
> 2. Definitions such as those `Interface.h` are indeed OpenMP-only
>
> 3. Some defintions could be useful for other languages as well, such as `Synchronization.h`. However, they are also in the `ompx` namespace
Yes, I strongly believe that `libomptarget` should eventually be moved back into `openmp/`. Long term I think `offload/` should contain the generic 'plugins' that provide an API for offloading to various GPUs. `libomptarget` then becomes the OpenMP runtime using that interface. There are arguments about some things in the current runtime are generically useful, but my assertion is that these should just be put in a separate library in `offload/` if that's the case. Combining everything into a single library is a holdover from before we had the appropriate infrastructure to easily create these, now it's trivial to just make a `liboffload.a` for the GPU.
> Honestly, I am thoroughly confused about all that openmp ↔ offload moving. But if these don't share much code with the current `openmp`, perhaps the cleanest approach would be to make it entirely separate?
Yeah, it's a little confusing because right now `offload/` has a direct dependency on `openmp` so they're effectively the same project.
https://github.com/llvm/llvm-project/pull/136729
More information about the Openmp-commits
mailing list