summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/video_core/buffer_cache/buffer_cache.h4
-rw-r--r--src/video_core/texture_cache/texture_cache.h10
2 files changed, 8 insertions, 6 deletions
diff --git a/src/video_core/buffer_cache/buffer_cache.h b/src/video_core/buffer_cache/buffer_cache.h
index 98756e4da..f3a6d5069 100644
--- a/src/video_core/buffer_cache/buffer_cache.h
+++ b/src/video_core/buffer_cache/buffer_cache.h
@@ -30,8 +30,8 @@ BufferCache<P>::BufferCache(VideoCore::RasterizerInterface& rasterizer_,
30 } 30 }
31 31
32 const s64 device_memory = static_cast<s64>(runtime.GetDeviceLocalMemory()); 32 const s64 device_memory = static_cast<s64>(runtime.GetDeviceLocalMemory());
33 const s64 min_spacing_expected = device_memory - 1_GiB - 512_MiB; 33 const s64 min_spacing_expected = device_memory - 1_GiB;
34 const s64 min_spacing_critical = device_memory - 1_GiB; 34 const s64 min_spacing_critical = device_memory - 512_MiB;
35 const s64 mem_threshold = std::min(device_memory, TARGET_THRESHOLD); 35 const s64 mem_threshold = std::min(device_memory, TARGET_THRESHOLD);
36 const s64 min_vacancy_expected = (6 * mem_threshold) / 10; 36 const s64 min_vacancy_expected = (6 * mem_threshold) / 10;
37 const s64 min_vacancy_critical = (3 * mem_threshold) / 10; 37 const s64 min_vacancy_critical = (3 * mem_threshold) / 10;
diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h
index b24086fce..6abafa877 100644
--- a/src/video_core/texture_cache/texture_cache.h
+++ b/src/video_core/texture_cache/texture_cache.h
@@ -49,8 +49,8 @@ TextureCache<P>::TextureCache(Runtime& runtime_, VideoCore::RasterizerInterface&
49 49
50 if constexpr (HAS_DEVICE_MEMORY_INFO) { 50 if constexpr (HAS_DEVICE_MEMORY_INFO) {
51 const s64 device_memory = static_cast<s64>(runtime.GetDeviceLocalMemory()); 51 const s64 device_memory = static_cast<s64>(runtime.GetDeviceLocalMemory());
52 const s64 min_spacing_expected = device_memory - 1_GiB - 512_MiB; 52 const s64 min_spacing_expected = device_memory - 1_GiB;
53 const s64 min_spacing_critical = device_memory - 1_GiB; 53 const s64 min_spacing_critical = device_memory - 512_MiB;
54 const s64 mem_threshold = std::min(device_memory, TARGET_THRESHOLD); 54 const s64 mem_threshold = std::min(device_memory, TARGET_THRESHOLD);
55 const s64 min_vacancy_expected = (6 * mem_threshold) / 10; 55 const s64 min_vacancy_expected = (6 * mem_threshold) / 10;
56 const s64 min_vacancy_critical = (3 * mem_threshold) / 10; 56 const s64 min_vacancy_critical = (3 * mem_threshold) / 10;
@@ -86,10 +86,12 @@ void TextureCache<P>::RunGarbageCollector() {
86 // used by the async decoder thread. 86 // used by the async decoder thread.
87 return false; 87 return false;
88 } 88 }
89 if (!aggressive_mode && True(image.flags & ImageFlagBits::CostlyLoad)) {
90 return false;
91 }
89 const bool must_download = 92 const bool must_download =
90 image.IsSafeDownload() && False(image.flags & ImageFlagBits::BadOverlap); 93 image.IsSafeDownload() && False(image.flags & ImageFlagBits::BadOverlap);
91 if (!high_priority_mode && 94 if (!high_priority_mode && must_download) {
92 (must_download || True(image.flags & ImageFlagBits::CostlyLoad))) {
93 return false; 95 return false;
94 } 96 }
95 if (must_download) { 97 if (must_download) {