Browse Source
Merge pull request #11859 from Kelebek1/compute_findbuffer
Add missing loop around compute FindBuffer calls
pull/15/merge
liamwhite
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
9 additions and
6 deletions
-
src/video_core/buffer_cache/buffer_cache.h
-
src/video_core/renderer_vulkan/vk_rasterizer.cpp
|
|
@ -1067,8 +1067,7 @@ void BufferCache<P>::BindHostComputeTextureBuffers() { |
|
|
|
|
|
|
|
|
template <class P> |
|
|
template <class P> |
|
|
void BufferCache<P>::DoUpdateGraphicsBuffers(bool is_indexed) { |
|
|
void BufferCache<P>::DoUpdateGraphicsBuffers(bool is_indexed) { |
|
|
do { |
|
|
|
|
|
channel_state->has_deleted_buffers = false; |
|
|
|
|
|
|
|
|
BufferOperations([&]() { |
|
|
if (is_indexed) { |
|
|
if (is_indexed) { |
|
|
UpdateIndexBuffer(); |
|
|
UpdateIndexBuffer(); |
|
|
} |
|
|
} |
|
|
@ -1082,14 +1081,16 @@ void BufferCache<P>::DoUpdateGraphicsBuffers(bool is_indexed) { |
|
|
if (current_draw_indirect) { |
|
|
if (current_draw_indirect) { |
|
|
UpdateDrawIndirect(); |
|
|
UpdateDrawIndirect(); |
|
|
} |
|
|
} |
|
|
} while (channel_state->has_deleted_buffers); |
|
|
|
|
|
|
|
|
}); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
template <class P> |
|
|
template <class P> |
|
|
void BufferCache<P>::DoUpdateComputeBuffers() { |
|
|
void BufferCache<P>::DoUpdateComputeBuffers() { |
|
|
UpdateComputeUniformBuffers(); |
|
|
|
|
|
UpdateComputeStorageBuffers(); |
|
|
|
|
|
UpdateComputeTextureBuffers(); |
|
|
|
|
|
|
|
|
BufferOperations([&]() { |
|
|
|
|
|
UpdateComputeUniformBuffers(); |
|
|
|
|
|
UpdateComputeStorageBuffers(); |
|
|
|
|
|
UpdateComputeTextureBuffers(); |
|
|
|
|
|
}); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
template <class P> |
|
|
template <class P> |
|
|
|
|
|
@ -13,6 +13,7 @@ |
|
|
#include "common/microprofile.h"
|
|
|
#include "common/microprofile.h"
|
|
|
#include "common/scope_exit.h"
|
|
|
#include "common/scope_exit.h"
|
|
|
#include "common/settings.h"
|
|
|
#include "common/settings.h"
|
|
|
|
|
|
#include "video_core/buffer_cache/buffer_cache.h"
|
|
|
#include "video_core/control/channel_state.h"
|
|
|
#include "video_core/control/channel_state.h"
|
|
|
#include "video_core/engines/draw_manager.h"
|
|
|
#include "video_core/engines/draw_manager.h"
|
|
|
#include "video_core/engines/kepler_compute.h"
|
|
|
#include "video_core/engines/kepler_compute.h"
|
|
|
@ -285,6 +286,7 @@ void RasterizerVulkan::DrawTexture() { |
|
|
|
|
|
|
|
|
query_cache.NotifySegment(true); |
|
|
query_cache.NotifySegment(true); |
|
|
|
|
|
|
|
|
|
|
|
std::scoped_lock l{texture_cache.mutex}; |
|
|
texture_cache.SynchronizeGraphicsDescriptors(); |
|
|
texture_cache.SynchronizeGraphicsDescriptors(); |
|
|
texture_cache.UpdateRenderTargets(false); |
|
|
texture_cache.UpdateRenderTargets(false); |
|
|
|
|
|
|
|
|
|