diff options
author | ReinUsesLisp <reinuseslisp@airmail.cc> | 2021-02-13 09:13:29 +0100 |
---|---|---|
committer | ReinUsesLisp <reinuseslisp@airmail.cc> | 2021-02-13 09:14:11 +0100 |
commit | 6171566296154963933fb8553c15b5316b5dda2f (patch) | |
tree | 1701d8363c0da07c7eda13929328e5a08e7f82cb /src/video_core/renderer_vulkan/vk_staging_buffer_pool.cpp | |
parent | gl_stream_buffer/vk_staging_buffer_pool: Fix size check (diff) | |
download | yuzu-6171566296154963933fb8553c15b5316b5dda2f.tar yuzu-6171566296154963933fb8553c15b5316b5dda2f.tar.gz yuzu-6171566296154963933fb8553c15b5316b5dda2f.tar.bz2 yuzu-6171566296154963933fb8553c15b5316b5dda2f.tar.lz yuzu-6171566296154963933fb8553c15b5316b5dda2f.tar.xz yuzu-6171566296154963933fb8553c15b5316b5dda2f.tar.zst yuzu-6171566296154963933fb8553c15b5316b5dda2f.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/renderer_vulkan/vk_staging_buffer_pool.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/video_core/renderer_vulkan/vk_staging_buffer_pool.cpp b/src/video_core/renderer_vulkan/vk_staging_buffer_pool.cpp index 9b5786fcb..7a1232497 100644 --- a/src/video_core/renderer_vulkan/vk_staging_buffer_pool.cpp +++ b/src/video_core/renderer_vulkan/vk_staging_buffer_pool.cpp @@ -175,8 +175,9 @@ StagingBufferRef StagingBufferPool::GetStreamBuffer(size_t size) { } bool StagingBufferPool::AreRegionsActive(size_t region_begin, size_t region_end) const { + const u64 gpu_tick = scheduler.GetMasterSemaphore().KnownGpuTick(); return std::any_of(sync_ticks.begin() + region_begin, sync_ticks.begin() + region_end, - [this](u64 sync_tick) { return !scheduler.IsFree(sync_tick); }); + [gpu_tick](u64 sync_tick) { return gpu_tick < sync_tick; }); }; StagingBufferRef StagingBufferPool::GetStagingBuffer(size_t size, MemoryUsage usage) { |