summaryrefslogtreecommitdiffstats
path: root/src/video_core
diff options
context:
space:
mode:
authorRodrigo Locatti <reinuseslisp@airmail.cc>2019-10-17 00:43:32 +0200
committerGitHub <noreply@github.com>2019-10-17 00:43:32 +0200
commite00b529a899d7a257ed5a120f11d2b032b5c8fed (patch)
tree2c9735c82a1935e30904da7aa08c006a13a0f739 /src/video_core
parentMerge pull request #2912 from FernandoS27/async-fixes (diff)
parenttexture_cache: Avoid unnecessary surface copies within PickStrategy() and TryReconstructSurface() (diff)
downloadyuzu-e00b529a899d7a257ed5a120f11d2b032b5c8fed.tar
yuzu-e00b529a899d7a257ed5a120f11d2b032b5c8fed.tar.gz
yuzu-e00b529a899d7a257ed5a120f11d2b032b5c8fed.tar.bz2
yuzu-e00b529a899d7a257ed5a120f11d2b032b5c8fed.tar.lz
yuzu-e00b529a899d7a257ed5a120f11d2b032b5c8fed.tar.xz
yuzu-e00b529a899d7a257ed5a120f11d2b032b5c8fed.tar.zst
yuzu-e00b529a899d7a257ed5a120f11d2b032b5c8fed.zip
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/texture_cache/texture_cache.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h
index ca2da8f97..0a23114f9 100644
--- a/src/video_core/texture_cache/texture_cache.h
+++ b/src/video_core/texture_cache/texture_cache.h
@@ -402,7 +402,7 @@ private:
if (params.block_depth > 1 || params.target == SurfaceTarget::Texture3D) {
return RecycleStrategy::Flush;
}
- for (auto s : overlaps) {
+ for (const auto& s : overlaps) {
const auto& s_params = s->GetSurfaceParams();
if (s_params.block_depth > 1 || s_params.target == SurfaceTarget::Texture3D) {
return RecycleStrategy::Flush;
@@ -575,7 +575,7 @@ private:
} else if (Settings::values.use_accurate_gpu_emulation && passed_tests != overlaps.size()) {
return {};
}
- for (auto surface : overlaps) {
+ for (const auto& surface : overlaps) {
Unregister(surface);
}
new_surface->MarkAsModified(modified, Tick());