aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFernando S <fsahmkow27@gmail.com>2022-03-24 17:13:46 +0100
committerGitHub <noreply@github.com>2022-03-24 17:13:46 +0100
commit0ea03225120447cf00388e7f1f5d33fd2ddbefc7 (patch)
tree36fb2a7ea7c64f3b26b3e2afae52bb4365bf5c5a /src
parentff090284b285a9436956f38275648afaeacf28d4 (diff)
parentc6b7c191eae71f1a7b83e443af12443278fcb487 (diff)
Merge pull request #8074 from liamwhite/cached-words
buffer_cache: reset cached write bits after flushing invalidations
Diffstat (limited to 'src')
-rw-r--r--src/video_core/buffer_cache/buffer_base.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/video_core/buffer_cache/buffer_base.h b/src/video_core/buffer_cache/buffer_base.h
index be2113f5a8..10975884bc 100644
--- a/src/video_core/buffer_cache/buffer_base.h
+++ b/src/video_core/buffer_cache/buffer_base.h
@@ -212,7 +212,7 @@ public:
void FlushCachedWrites() noexcept {
flags &= ~BufferFlagBits::CachedWrites;
const u64 num_words = NumWords();
- const u64* const cached_words = Array<Type::CachedCPU>();
+ u64* const cached_words = Array<Type::CachedCPU>();
u64* const untracked_words = Array<Type::Untracked>();
u64* const cpu_words = Array<Type::CPU>();
for (u64 word_index = 0; word_index < num_words; ++word_index) {
@@ -220,6 +220,7 @@ public:
NotifyRasterizer<false>(word_index, untracked_words[word_index], cached_bits);
untracked_words[word_index] |= cached_bits;
cpu_words[word_index] |= cached_bits;
+ cached_words[word_index] = 0;
}
}