summaryrefslogtreecommitdiffstats
path: root/src/video_core/memory_manager.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2018-07-02 17:48:18 +0200
committerGitHub <noreply@github.com>2018-07-02 17:48:18 +0200
commit3d41fdfbba48f92e8d433085cc66cd4ef50b03ab (patch)
treea7441d8c1c03d0e1ebe7a81b5e4a01f1de45251c /src/video_core/memory_manager.cpp
parentMerge pull request #602 from Subv/mufu_subop (diff)
parentGPU: Ignore disabled textures and textures with an invalid address. (diff)
downloadyuzu-3d41fdfbba48f92e8d433085cc66cd4ef50b03ab.tar
yuzu-3d41fdfbba48f92e8d433085cc66cd4ef50b03ab.tar.gz
yuzu-3d41fdfbba48f92e8d433085cc66cd4ef50b03ab.tar.bz2
yuzu-3d41fdfbba48f92e8d433085cc66cd4ef50b03ab.tar.lz
yuzu-3d41fdfbba48f92e8d433085cc66cd4ef50b03ab.tar.xz
yuzu-3d41fdfbba48f92e8d433085cc66cd4ef50b03ab.tar.zst
yuzu-3d41fdfbba48f92e8d433085cc66cd4ef50b03ab.zip
Diffstat (limited to 'src/video_core/memory_manager.cpp')
-rw-r--r--src/video_core/memory_manager.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/memory_manager.cpp b/src/video_core/memory_manager.cpp
index 5cefce9fc..2f814a184 100644
--- a/src/video_core/memory_manager.cpp
+++ b/src/video_core/memory_manager.cpp
@@ -100,9 +100,9 @@ boost::optional<GPUVAddr> MemoryManager::FindFreeBlock(u64 size, u64 align) {
boost::optional<VAddr> MemoryManager::GpuToCpuAddress(GPUVAddr gpu_addr) {
VAddr base_addr = PageSlot(gpu_addr);
- ASSERT(base_addr != static_cast<u64>(PageStatus::Unmapped));
- if (base_addr == static_cast<u64>(PageStatus::Allocated)) {
+ if (base_addr == static_cast<u64>(PageStatus::Allocated) ||
+ base_addr == static_cast<u64>(PageStatus::Unmapped)) {
return {};
}