Fix Vulkan Tracy timestamp queries on MoltenVK

Disable Vulkan Tracy GPU profiling when Vulkan timer queries are disabled.
Apple platforms already set VULKAN_USE_TIMER_QUERIES to 0
This commit is contained in:
Andrei Gagua
2026-05-24 11:13:41 +03:00
parent 00e4b09e7e
commit 285762bfdb
6 changed files with 16 additions and 10 deletions
@@ -57,7 +57,7 @@ void CmdBufferVulkan::End()
if (vkCmdEndDebugUtilsLabelEXT)
vkCmdEndDebugUtilsLabelEXT(GetHandle());
#endif
#if GPU_ENABLE_TRACY
#if VULKAN_USE_TRACY_GPU
tracy::EndVkZoneScope(_tracyZones.Last().Data);
_tracyZones.RemoveLast();
#endif
@@ -101,7 +101,7 @@ void CmdBufferVulkan::BeginEvent(const Char* name, void* tracyContext)
char buffer[60];
int32 bufferSize = StringUtils::Copy(buffer, name, sizeof(buffer));
#if GPU_ENABLE_TRACY
#if VULKAN_USE_TRACY_GPU
auto& zone = _tracyZones.AddOne();
tracy::BeginVkZoneScope(zone.Data, tracyContext, GetHandle(), buffer, bufferSize);
#endif
@@ -128,7 +128,7 @@ void CmdBufferVulkan::EndEvent()
vkCmdEndDebugUtilsLabelEXT(GetHandle());
#endif
#if GPU_ENABLE_TRACY
#if VULKAN_USE_TRACY_GPU
tracy::EndVkZoneScope(_tracyZones.Last().Data);
_tracyZones.RemoveLast();
#endif