From 7fc06260d1fa8d0e18e7fc0ea80a16d1bb4ee29c Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 16 Dec 2023 18:57:23 -0500 Subject: renderer_vulkan: allow up to 7 swapchain images --- src/video_core/fence_manager.h | 2 +- src/video_core/renderer_vulkan/vk_present_manager.cpp | 6 +++--- src/video_core/renderer_vulkan/vk_update_descriptor.h | 2 +- src/video_core/texture_cache/texture_cache_base.h | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src/video_core') diff --git a/src/video_core/fence_manager.h b/src/video_core/fence_manager.h index 805a89900..c3eda6893 100644 --- a/src/video_core/fence_manager.h +++ b/src/video_core/fence_manager.h @@ -270,7 +270,7 @@ private: std::jthread fence_thread; - DelayedDestructionRing delayed_destruction_ring; + DelayedDestructionRing delayed_destruction_ring; }; } // namespace VideoCommon diff --git a/src/video_core/renderer_vulkan/vk_present_manager.cpp b/src/video_core/renderer_vulkan/vk_present_manager.cpp index a59e2d2d1..5e7518d96 100644 --- a/src/video_core/renderer_vulkan/vk_present_manager.cpp +++ b/src/video_core/renderer_vulkan/vk_present_manager.cpp @@ -293,10 +293,10 @@ void PresentManager::RecreateSwapchain(Frame* frame) { } void PresentManager::SetImageCount() { - // We cannot have more than 5 images in flight at any given time. - // FRAMES_IN_FLIGHT is 7, and the cache TICKS_TO_DESTROY is 6. + // We cannot have more than 7 images in flight at any given time. + // FRAMES_IN_FLIGHT is 8, and the cache TICKS_TO_DESTROY is 8. // Mali drivers will give us 6. - image_count = std::min(swapchain.GetImageCount(), 5); + image_count = std::min(swapchain.GetImageCount(), 7); } void PresentManager::CopyToSwapchain(Frame* frame) { diff --git a/src/video_core/renderer_vulkan/vk_update_descriptor.h b/src/video_core/renderer_vulkan/vk_update_descriptor.h index e77b576ec..82fce298d 100644 --- a/src/video_core/renderer_vulkan/vk_update_descriptor.h +++ b/src/video_core/renderer_vulkan/vk_update_descriptor.h @@ -31,7 +31,7 @@ struct DescriptorUpdateEntry { class UpdateDescriptorQueue final { // This should be plenty for the vast majority of cases. Most desktop platforms only // provide up to 3 swapchain images. - static constexpr size_t FRAMES_IN_FLIGHT = 7; + static constexpr size_t FRAMES_IN_FLIGHT = 8; static constexpr size_t FRAME_PAYLOAD_SIZE = 0x20000; static constexpr size_t PAYLOAD_SIZE = FRAME_PAYLOAD_SIZE * FRAMES_IN_FLIGHT; diff --git a/src/video_core/texture_cache/texture_cache_base.h b/src/video_core/texture_cache/texture_cache_base.h index cbe56e166..6caf75b46 100644 --- a/src/video_core/texture_cache/texture_cache_base.h +++ b/src/video_core/texture_cache/texture_cache_base.h @@ -474,7 +474,7 @@ private: }; Common::LeastRecentlyUsedCache lru_cache; - static constexpr size_t TICKS_TO_DESTROY = 6; + static constexpr size_t TICKS_TO_DESTROY = 8; DelayedDestructionRing sentenced_images; DelayedDestructionRing sentenced_image_view; DelayedDestructionRing sentenced_framebuffers; -- cgit v1.2.3