From 801741e7870a3e4f943a8628447c5eac74ecb2e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pedro=20J=2E=20Est=C3=A9banez?= Date: Thu, 24 Feb 2022 12:47:34 +0100 Subject: vk_mem_alloc: Update to upstream + Adapt approach to small objects pooling This updates VMA and instead of using the custom small pool approach from 4e6c9d3ae979f2eb0151cf581fe61d2f3194ea72, lazily creates pools for the relevant memory type indices, which doesn't require patching VMA. Also, patches already merged upstream or not needed any longer are removed. --- drivers/vulkan/rendering_device_vulkan.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'drivers/vulkan/rendering_device_vulkan.h') diff --git a/drivers/vulkan/rendering_device_vulkan.h b/drivers/vulkan/rendering_device_vulkan.h index 3e4327667b..126f6f8ad0 100644 --- a/drivers/vulkan/rendering_device_vulkan.h +++ b/drivers/vulkan/rendering_device_vulkan.h @@ -1016,7 +1016,8 @@ class RenderingDeviceVulkan : public RenderingDevice { void _free_pending_resources(int p_frame); VmaAllocator allocator = nullptr; - VmaPool small_allocs_pool = nullptr; + Map small_allocs_pools; + VmaPool _find_or_create_small_allocs_pool(uint32_t p_mem_type_index); VulkanContext *context = nullptr; -- cgit v1.2.3