[Openmp-commits] [clang] [openmp] [OFFLOAD] Build DeviceRTL with SPIRV backend (PR #174675)
Joseph Huber via Openmp-commits
openmp-commits at lists.llvm.org
Fri Jan 9 16:53:01 PST 2026
================
@@ -23,13 +23,17 @@ _Pragma("omp begin declare variant match(device = {arch(spirv64)})");
// Type aliases to the address spaces used by the SPIR-V backend.
#define __gpu_private __attribute__((address_space(0)))
#define __gpu_constant __attribute__((address_space(2)))
-#define __gpu_local __attribute__((address_space(3)))
+#define __gpu_local __attribute__((address_space(3)))
#define __gpu_global __attribute__((address_space(1)))
#define __gpu_generic __attribute__((address_space(4)))
// Attribute to declare a function as a kernel.
#define __gpu_kernel __attribute__((device_kernel, visibility("protected")))
+#ifdef __cplusplus
+template <typename... Args> int __spirv_ocl_printf(Args...);
+#endif
+
----------------
jhuber6 wrote:
This belongs next to the usage
https://github.com/llvm/llvm-project/pull/174675
More information about the Openmp-commits
mailing list