vulkan: Add CPU tracing for vkWaitForFences.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22505>
This commit is contained in:
parent
d980f311b7
commit
4eb57ab97a
2 changed files with 6 additions and 0 deletions
|
|
@ -24,6 +24,7 @@
|
||||||
#include "vk_fence.h"
|
#include "vk_fence.h"
|
||||||
|
|
||||||
#include "util/os_time.h"
|
#include "util/os_time.h"
|
||||||
|
#include "util/perf/cpu_trace.h"
|
||||||
|
|
||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
@ -252,6 +253,8 @@ vk_common_WaitForFences(VkDevice _device,
|
||||||
VkBool32 waitAll,
|
VkBool32 waitAll,
|
||||||
uint64_t timeout)
|
uint64_t timeout)
|
||||||
{
|
{
|
||||||
|
MESA_TRACE_FUNC();
|
||||||
|
|
||||||
VK_FROM_HANDLE(vk_device, device, _device);
|
VK_FROM_HANDLE(vk_device, device, _device);
|
||||||
|
|
||||||
if (vk_device_is_lost(device))
|
if (vk_device_is_lost(device))
|
||||||
|
|
|
||||||
|
|
@ -24,6 +24,7 @@
|
||||||
#include "vk_instance.h"
|
#include "vk_instance.h"
|
||||||
|
|
||||||
#include "util/libdrm.h"
|
#include "util/libdrm.h"
|
||||||
|
#include "util/perf/cpu_trace.h"
|
||||||
|
|
||||||
#include "vk_alloc.h"
|
#include "vk_alloc.h"
|
||||||
#include "vk_common_entrypoints.h"
|
#include "vk_common_entrypoints.h"
|
||||||
|
|
@ -54,6 +55,8 @@ vk_instance_init(struct vk_instance *instance,
|
||||||
vk_object_base_init(NULL, &instance->base, VK_OBJECT_TYPE_INSTANCE);
|
vk_object_base_init(NULL, &instance->base, VK_OBJECT_TYPE_INSTANCE);
|
||||||
instance->alloc = *alloc;
|
instance->alloc = *alloc;
|
||||||
|
|
||||||
|
util_cpu_trace_init();
|
||||||
|
|
||||||
/* VK_EXT_debug_utils */
|
/* VK_EXT_debug_utils */
|
||||||
/* These messengers will only be used during vkCreateInstance or
|
/* These messengers will only be used during vkCreateInstance or
|
||||||
* vkDestroyInstance calls. We do this first so that it's safe to use
|
* vkDestroyInstance calls. We do this first so that it's safe to use
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue