diff options
author | Fernando S <fsahmkow27@gmail.com> | 2022-01-06 13:50:14 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-06 13:50:14 +0100 |
commit | a95c49e7d0cb7d38e3db96023c40af551c681259 (patch) | |
tree | 2ee70e5b487cfc01b7a08350c269b0f569fa216e /src/video_core/texture_cache | |
parent | Merge pull request #7679 from liushuyu/update-dynarmic (diff) | |
parent | video_core/memory_manager: Fixes for sparse memory management (diff) | |
download | yuzu-a95c49e7d0cb7d38e3db96023c40af551c681259.tar yuzu-a95c49e7d0cb7d38e3db96023c40af551c681259.tar.gz yuzu-a95c49e7d0cb7d38e3db96023c40af551c681259.tar.bz2 yuzu-a95c49e7d0cb7d38e3db96023c40af551c681259.tar.lz yuzu-a95c49e7d0cb7d38e3db96023c40af551c681259.tar.xz yuzu-a95c49e7d0cb7d38e3db96023c40af551c681259.tar.zst yuzu-a95c49e7d0cb7d38e3db96023c40af551c681259.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/texture_cache/texture_cache.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h index b494152b8..198bb0cfb 100644 --- a/src/video_core/texture_cache/texture_cache.h +++ b/src/video_core/texture_cache/texture_cache.h @@ -1376,9 +1376,7 @@ void TextureCache<P>::ForEachSparseSegment(ImageBase& image, Func&& func) { using FuncReturn = typename std::invoke_result<Func, GPUVAddr, VAddr, size_t>::type; static constexpr bool RETURNS_BOOL = std::is_same_v<FuncReturn, bool>; const auto segments = gpu_memory.GetSubmappedRange(image.gpu_addr, image.guest_size_bytes); - for (auto& segment : segments) { - const auto gpu_addr = segment.first; - const auto size = segment.second; + for (const auto& [gpu_addr, size] : segments) { std::optional<VAddr> cpu_addr = gpu_memory.GpuToCpuAddress(gpu_addr); ASSERT(cpu_addr); if constexpr (RETURNS_BOOL) { |