diff --git a/gapir/cc/linux/vulkan_renderer.cpp b/gapir/cc/linux/vulkan_renderer.cpp index 86f5360a41..41e96aee3d 100644 --- a/gapir/cc/linux/vulkan_renderer.cpp +++ b/gapir/cc/linux/vulkan_renderer.cpp @@ -34,6 +34,21 @@ class VulkanRendererImpl : public VulkanRenderer { VulkanRendererImpl::VulkanRendererImpl() { mApi.resolve(); + // Create a dummy instance renderer that never gets cleaned up. + // This works around some driver bugs. + // See https://github.com/google/gapid/issues/1899 + auto create_info = Vulkan::VkInstanceCreateInfo{ + Vulkan::VkStructureType::VK_STRUCTURE_TYPE_INSTANCE_CREATE_INFO, + nullptr, + 0, + nullptr, + 0, + nullptr, + 0, + nullptr + }; + Vulkan::VkInstance inst; + mApi.mFunctionStubs.vkCreateInstance(&create_info, nullptr, &inst); } VulkanRendererImpl::~VulkanRendererImpl() {