diff options
Diffstat (limited to 'src/video_core/vulkan_common')
-rw-r--r-- | src/video_core/vulkan_common/vulkan_device.cpp | 8 | ||||
-rw-r--r-- | src/video_core/vulkan_common/vulkan_wrapper.cpp | 7 | ||||
-rw-r--r-- | src/video_core/vulkan_common/vulkan_wrapper.h | 6 |
3 files changed, 11 insertions, 10 deletions
diff --git a/src/video_core/vulkan_common/vulkan_device.cpp b/src/video_core/vulkan_common/vulkan_device.cpp index 72968a01c..c2bea3e9e 100644 --- a/src/video_core/vulkan_common/vulkan_device.cpp +++ b/src/video_core/vulkan_common/vulkan_device.cpp @@ -77,10 +77,6 @@ enum class NvidiaArchitecture { constexpr std::array REQUIRED_EXTENSIONS{ VK_EXT_VERTEX_ATTRIBUTE_DIVISOR_EXTENSION_NAME, VK_EXT_ROBUSTNESS_2_EXTENSION_NAME, - - // Core in 1.2, but required due to use of extension methods, - // and well-supported by drivers - VK_EXT_HOST_QUERY_RESET_EXTENSION_NAME, #ifdef _WIN32 VK_KHR_EXTERNAL_MEMORY_WIN32_EXTENSION_NAME, #endif @@ -438,8 +434,8 @@ Device::Device(VkInstance instance_, vk::PhysicalDevice physical_, VkSurfaceKHR }; SetNext(next, robustness2); - VkPhysicalDeviceHostQueryResetFeaturesEXT host_query_reset{ - .sType = VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_HOST_QUERY_RESET_FEATURES_EXT, + VkPhysicalDeviceHostQueryResetFeatures host_query_reset{ + .sType = VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_HOST_QUERY_RESET_FEATURES, .pNext = nullptr, .hostQueryReset = true, }; diff --git a/src/video_core/vulkan_common/vulkan_wrapper.cpp b/src/video_core/vulkan_common/vulkan_wrapper.cpp index f842524c4..1592d4184 100644 --- a/src/video_core/vulkan_common/vulkan_wrapper.cpp +++ b/src/video_core/vulkan_common/vulkan_wrapper.cpp @@ -184,7 +184,7 @@ void Load(VkDevice device, DeviceDispatch& dld) noexcept { X(vkMapMemory); X(vkQueueSubmit); X(vkResetFences); - X(vkResetQueryPoolEXT); + X(vkResetQueryPool); X(vkSetDebugUtilsObjectNameEXT); X(vkSetDebugUtilsObjectTagEXT); X(vkUnmapMemory); @@ -199,6 +199,11 @@ void Load(VkDevice device, DeviceDispatch& dld) noexcept { Proc(dld.vkWaitForFences, dld, "vkWaitForFencesKHR", device); Proc(dld.vkWaitSemaphores, dld, "vkWaitSemaphoresKHR", device); } + + // Support for host query reset is mandatory in Vulkan 1.2 + if (!dld.vkResetQueryPool) { + Proc(dld.vkResetQueryPool, dld, "vkResetQueryPoolEXT", device); + } #undef X } diff --git a/src/video_core/vulkan_common/vulkan_wrapper.h b/src/video_core/vulkan_common/vulkan_wrapper.h index 101205386..9997420dd 100644 --- a/src/video_core/vulkan_common/vulkan_wrapper.h +++ b/src/video_core/vulkan_common/vulkan_wrapper.h @@ -301,7 +301,7 @@ struct DeviceDispatch : InstanceDispatch { PFN_vkMapMemory vkMapMemory{}; PFN_vkQueueSubmit vkQueueSubmit{}; PFN_vkResetFences vkResetFences{}; - PFN_vkResetQueryPoolEXT vkResetQueryPoolEXT{}; + PFN_vkResetQueryPool vkResetQueryPool{}; PFN_vkSetDebugUtilsObjectNameEXT vkSetDebugUtilsObjectNameEXT{}; PFN_vkSetDebugUtilsObjectTagEXT vkSetDebugUtilsObjectTagEXT{}; PFN_vkUnmapMemory vkUnmapMemory{}; @@ -884,8 +884,8 @@ public: return dld->vkDeviceWaitIdle(handle); } - void ResetQueryPoolEXT(VkQueryPool query_pool, u32 first, u32 count) const noexcept { - dld->vkResetQueryPoolEXT(handle, query_pool, first, count); + void ResetQueryPool(VkQueryPool query_pool, u32 first, u32 count) const noexcept { + dld->vkResetQueryPool(handle, query_pool, first, count); } VkResult GetQueryResults(VkQueryPool query_pool, u32 first, u32 count, std::size_t data_size, |