summaryrefslogtreecommitdiff
path: root/src/video_core/vulkan_common
diff options
context:
space:
mode:
authorGravatar Fernando Sahmkow2021-08-29 22:45:17 +0200
committerGravatar Fernando Sahmkow2021-09-13 23:09:18 +0200
commite7ca37b1e5d6dd62870c7b7c953598ad7785c9f9 (patch)
tree8b3b8634c7b6910acdd2bc1363b4770dba2f1397 /src/video_core/vulkan_common
parentMerge pull request #6929 from yuzu-emu/revert-6870-trace-back-stack-back-stac... (diff)
downloadyuzu-e7ca37b1e5d6dd62870c7b7c953598ad7785c9f9.tar.gz
yuzu-e7ca37b1e5d6dd62870c7b7c953598ad7785c9f9.tar.xz
yuzu-e7ca37b1e5d6dd62870c7b7c953598ad7785c9f9.zip
Vulkan/Descriptors: Increase sets per pool on AMFD propietary driver.
Diffstat (limited to 'src/video_core/vulkan_common')
-rw-r--r--src/video_core/vulkan_common/vulkan_device.cpp6
-rw-r--r--src/video_core/vulkan_common/vulkan_device.h5
2 files changed, 11 insertions, 0 deletions
diff --git a/src/video_core/vulkan_common/vulkan_device.cpp b/src/video_core/vulkan_common/vulkan_device.cpp
index 86ca4be54..5662a7bdc 100644
--- a/src/video_core/vulkan_common/vulkan_device.cpp
+++ b/src/video_core/vulkan_common/vulkan_device.cpp
@@ -599,6 +599,12 @@ Device::Device(VkInstance instance_, vk::PhysicalDevice physical_, VkSurfaceKHR
599 599
600 graphics_queue = logical.GetQueue(graphics_family); 600 graphics_queue = logical.GetQueue(graphics_family);
601 present_queue = logical.GetQueue(present_family); 601 present_queue = logical.GetQueue(present_family);
602
603 sets_per_pool = 64;
604 if (driver_id == VK_DRIVER_ID_AMD_PROPRIETARY || driver_id == VK_DRIVER_ID_AMD_OPEN_SOURCE) {
605 // AMD drivers need a higher amount of Sets per Pool in certain circunstances like in XC2.
606 sets_per_pool = 96;
607 }
602} 608}
603 609
604Device::~Device() = default; 610Device::~Device() = default;
diff --git a/src/video_core/vulkan_common/vulkan_device.h b/src/video_core/vulkan_common/vulkan_device.h
index 234d74129..9d1cb9181 100644
--- a/src/video_core/vulkan_common/vulkan_device.h
+++ b/src/video_core/vulkan_common/vulkan_device.h
@@ -318,6 +318,10 @@ public:
318 return device_access_memory; 318 return device_access_memory;
319 } 319 }
320 320
321 u32 GetSetsPerPool() const {
322 return sets_per_pool;
323 }
324
321private: 325private:
322 /// Checks if the physical device is suitable. 326 /// Checks if the physical device is suitable.
323 void CheckSuitability(bool requires_swapchain) const; 327 void CheckSuitability(bool requires_swapchain) const;
@@ -371,6 +375,7 @@ private:
371 VkShaderStageFlags guest_warp_stages{}; ///< Stages where the guest warp size can be forced. 375 VkShaderStageFlags guest_warp_stages{}; ///< Stages where the guest warp size can be forced.
372 u64 device_access_memory{}; ///< Total size of device local memory in bytes. 376 u64 device_access_memory{}; ///< Total size of device local memory in bytes.
373 u32 max_push_descriptors{}; ///< Maximum number of push descriptors 377 u32 max_push_descriptors{}; ///< Maximum number of push descriptors
378 u32 sets_per_pool{}; ///< Sets per Description Pool
374 bool is_optimal_astc_supported{}; ///< Support for native ASTC. 379 bool is_optimal_astc_supported{}; ///< Support for native ASTC.
375 bool is_float16_supported{}; ///< Support for float16 arithmetic. 380 bool is_float16_supported{}; ///< Support for float16 arithmetic.
376 bool is_int8_supported{}; ///< Support for int8 arithmetic. 381 bool is_int8_supported{}; ///< Support for int8 arithmetic.