17 #ifndef KOKKOS_PRINTF_HPP
18 #define KOKKOS_PRINTF_HPP
20 #include <Kokkos_Macros.hpp>
22 #ifdef KOKKOS_ENABLE_SYCL
23 #include <sycl/sycl.hpp>
33 #if defined(KOKKOS_ENABLE_OPENMPTARGET) && defined(KOKKOS_ARCH_INTEL_GPU)
36 template <
typename... Args>
37 KOKKOS_FORCEINLINE_FUNCTION
void printf(
const char* format, Args... args) {
38 #ifdef KOKKOS_ENABLE_SYCL
40 if constexpr (
sizeof...(Args) == 0)
41 sycl::ext::oneapi::experimental::printf("%s", format);
43 sycl::ext::oneapi::experimental::printf(format, args...);
45 if constexpr (
sizeof...(Args) == 0)
46 ::printf(
"%s", format);
48 ::printf(format, args...);