diff options
author | liamwhite <liamwhite@users.noreply.github.com> | 2023-12-18 00:59:49 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-18 00:59:49 +0100 |
commit | 65e646eeba53fe1067b7d69044ddabaee18d868f (patch) | |
tree | 9cd2c5d264e623060186bd51e9c07433e9629234 /src/video_core/texture_cache | |
parent | Merge pull request #12378 from liamwhite/offsetof (diff) | |
download | yuzu-65e646eeba53fe1067b7d69044ddabaee18d868f.tar yuzu-65e646eeba53fe1067b7d69044ddabaee18d868f.tar.gz yuzu-65e646eeba53fe1067b7d69044ddabaee18d868f.tar.bz2 yuzu-65e646eeba53fe1067b7d69044ddabaee18d868f.tar.lz yuzu-65e646eeba53fe1067b7d69044ddabaee18d868f.tar.xz yuzu-65e646eeba53fe1067b7d69044ddabaee18d868f.tar.zst yuzu-65e646eeba53fe1067b7d69044ddabaee18d868f.zip |
Diffstat (limited to 'src/video_core/texture_cache')
-rw-r--r-- | src/video_core/texture_cache/texture_cache.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h index d7941f6a4..0d5a1709f 100644 --- a/src/video_core/texture_cache/texture_cache.h +++ b/src/video_core/texture_cache/texture_cache.h @@ -2080,7 +2080,7 @@ void TextureCache<P>::TrackImage(ImageBase& image, ImageId image_id) { ASSERT(False(image.flags & ImageFlagBits::Tracked)); image.flags |= ImageFlagBits::Tracked; if (False(image.flags & ImageFlagBits::Sparse)) { - rasterizer.UpdatePagesCachedCount(image.cpu_addr, image.guest_size_bytes, true); + rasterizer.UpdatePagesCachedCount(image.cpu_addr, image.guest_size_bytes, 1); return; } if (True(image.flags & ImageFlagBits::Registered)) { @@ -2091,13 +2091,13 @@ void TextureCache<P>::TrackImage(ImageBase& image, ImageId image_id) { const auto& map = slot_map_views[map_view_id]; const VAddr cpu_addr = map.cpu_addr; const std::size_t size = map.size; - rasterizer.UpdatePagesCachedCount(cpu_addr, size, true); + rasterizer.UpdatePagesCachedCount(cpu_addr, size, 1); } return; } ForEachSparseSegment(image, [this]([[maybe_unused]] GPUVAddr gpu_addr, VAddr cpu_addr, size_t size) { - rasterizer.UpdatePagesCachedCount(cpu_addr, size, true); + rasterizer.UpdatePagesCachedCount(cpu_addr, size, 1); }); } @@ -2106,7 +2106,7 @@ void TextureCache<P>::UntrackImage(ImageBase& image, ImageId image_id) { ASSERT(True(image.flags & ImageFlagBits::Tracked)); image.flags &= ~ImageFlagBits::Tracked; if (False(image.flags & ImageFlagBits::Sparse)) { - rasterizer.UpdatePagesCachedCount(image.cpu_addr, image.guest_size_bytes, false); + rasterizer.UpdatePagesCachedCount(image.cpu_addr, image.guest_size_bytes, -1); return; } ASSERT(True(image.flags & ImageFlagBits::Registered)); @@ -2117,7 +2117,7 @@ void TextureCache<P>::UntrackImage(ImageBase& image, ImageId image_id) { const auto& map = slot_map_views[map_view_id]; const VAddr cpu_addr = map.cpu_addr; const std::size_t size = map.size; - rasterizer.UpdatePagesCachedCount(cpu_addr, size, false); + rasterizer.UpdatePagesCachedCount(cpu_addr, size, -1); } } |