diff options
author | Lioncash <mathew1800@gmail.com> | 2019-04-06 02:18:27 +0200 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2019-04-06 02:18:29 +0200 |
commit | 9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d (patch) | |
tree | 13001b2f2e22d963ab0043daf17d6220cc59ad75 /src/video_core/memory_manager.cpp | |
parent | Merge pull request #2282 from bunnei/gpu-asynch-v2 (diff) | |
download | yuzu-9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d.tar yuzu-9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d.tar.gz yuzu-9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d.tar.bz2 yuzu-9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d.tar.lz yuzu-9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d.tar.xz yuzu-9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d.tar.zst yuzu-9dec087fca5944b6e4ee5f0f76c0716a93a9fe4d.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/memory_manager.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/memory_manager.cpp b/src/video_core/memory_manager.cpp index e76b59842..124a3c6d2 100644 --- a/src/video_core/memory_manager.cpp +++ b/src/video_core/memory_manager.cpp @@ -99,12 +99,12 @@ bool MemoryManager::IsAddressValid(GPUVAddr addr) const { return (addr >> page_bits) < page_table.pointers.size(); } -std::optional<VAddr> MemoryManager::GpuToCpuAddress(GPUVAddr addr) { +std::optional<VAddr> MemoryManager::GpuToCpuAddress(GPUVAddr addr) const { if (!IsAddressValid(addr)) { return {}; } - VAddr cpu_addr{page_table.backing_addr[addr >> page_bits]}; + const VAddr cpu_addr{page_table.backing_addr[addr >> page_bits]}; if (cpu_addr) { return cpu_addr + (addr & page_mask); } |