[vulkan] Add unwrap hook for QueueSubmit and semaphore resource tracking
Change-Id: I491e3c226186968bf6b692e513d9ea5c1052b609
diff --git a/system/vulkan/func_table.cpp b/system/vulkan/func_table.cpp
index 3099285..2e89514 100644
--- a/system/vulkan/func_table.cpp
+++ b/system/vulkan/func_table.cpp
@@ -437,7 +437,8 @@
{
auto vkEnc = HostConnection::get()->vkEncoder();
VkResult vkCreateSemaphore_VkResult_return = (VkResult)0;
- vkCreateSemaphore_VkResult_return = vkEnc->vkCreateSemaphore(device, pCreateInfo, pAllocator, pSemaphore);
+ auto resources = ResourceTracker::get();
+ vkCreateSemaphore_VkResult_return = resources->on_vkCreateSemaphore(vkEnc, VK_SUCCESS, device, pCreateInfo, pAllocator, pSemaphore);
return vkCreateSemaphore_VkResult_return;
}
static void entry_vkDestroySemaphore(
@@ -446,7 +447,8 @@
const VkAllocationCallbacks* pAllocator)
{
auto vkEnc = HostConnection::get()->vkEncoder();
- vkEnc->vkDestroySemaphore(device, semaphore, pAllocator);
+ auto resources = ResourceTracker::get();
+ resources->on_vkDestroySemaphore(vkEnc, device, semaphore, pAllocator);
}
static VkResult entry_vkCreateEvent(
VkDevice device,