[Openmp-commits] [PATCH] D144893: [OpenMP][WIP] `spir64` device runtime library template
Jean-Baptiste Skutnik via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Mon Mar 6 09:52:30 PST 2023
spoutn1k marked 2 inline comments as done.
spoutn1k added inline comments.
================
Comment at: llvm/lib/Frontend/OpenMP/OMPContext.cpp:55
+ case Triple::spir64:
ActiveTraits.set(unsigned(TraitProperty::device_kind_gpu));
break;
----------------
tianshilei1992 wrote:
> SPIR-V can be for host as well right? OpenCL CPU runtime can also take SPIR-V.
It can ! The objective of this work is to use it with intel gpus. I put it there in order to have it understand the variants in DeviceRTL. Is there a way to signify both host and device ?
================
Comment at: openmp/libomptarget/DeviceRTL/src/LibC.cpp:37
+/// Intel implementation
+#pragma omp begin declare variant match(device = {arch(spir64)})
+namespace impl {
----------------
tianshilei1992 wrote:
> I'm thinking potentially we can have a generic implementation of `omp_vprintf` that just returns -1 and having the NVPTX version calls `vprintf`. In this way we don't need to do it for every target.
How do I go about doing this ? Declare `omp_vprintf` as weak ?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144893/new/
https://reviews.llvm.org/D144893
More information about the Openmp-commits
mailing list