From 0bbba872063d1363040ab77a15c32c5e93df4098 Mon Sep 17 00:00:00 2001 From: Maarten Arnst Date: Sun, 6 Oct 2024 08:25:19 +0200 Subject: [PATCH] Update Kokkos_Profiling_Interface.hpp after kokkos pr 7394 --- profiling/all/impl/Kokkos_Profiling_Interface.hpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/profiling/all/impl/Kokkos_Profiling_Interface.hpp b/profiling/all/impl/Kokkos_Profiling_Interface.hpp index b66886d9f..ddd6223be 100644 --- a/profiling/all/impl/Kokkos_Profiling_Interface.hpp +++ b/profiling/all/impl/Kokkos_Profiling_Interface.hpp @@ -101,6 +101,15 @@ inline uint32_t device_id(ExecutionSpace const& space) noexcept { << num_instance_bits) + space.impl_instance_id(); } + +inline uint32_t int_for_synchronization_reason( + Kokkos::Tools::Experimental::SpecialSynchronizationCases reason) { + switch (reason) { + case GlobalDeviceSynchronization: return 0; + case DeepCopyResourceSynchronization: return 0x00ffffff; + } + return 0; +} } // namespace Experimental } // namespace Tools } // end namespace Kokkos