diff options
author | Subv <subv2112@gmail.com> | 2018-04-23 17:57:12 +0200 |
---|---|---|
committer | Subv <subv2112@gmail.com> | 2018-04-23 17:57:12 +0200 |
commit | f823c1d5991657a3d91f97c345e1f01a1162fca7 (patch) | |
tree | 2c8b8ee29b9af9d40a61b7b0b8ce99834d45cd58 /src/video_core/memory_manager.h | |
parent | Merge pull request #377 from adityaruplaha/sdl2-fullscreen (diff) | |
download | yuzu-f823c1d5991657a3d91f97c345e1f01a1162fca7.tar yuzu-f823c1d5991657a3d91f97c345e1f01a1162fca7.tar.gz yuzu-f823c1d5991657a3d91f97c345e1f01a1162fca7.tar.bz2 yuzu-f823c1d5991657a3d91f97c345e1f01a1162fca7.tar.lz yuzu-f823c1d5991657a3d91f97c345e1f01a1162fca7.tar.xz yuzu-f823c1d5991657a3d91f97c345e1f01a1162fca7.tar.zst yuzu-f823c1d5991657a3d91f97c345e1f01a1162fca7.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/memory_manager.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/video_core/memory_manager.h b/src/video_core/memory_manager.h index 47da7acd6..b73e283f8 100644 --- a/src/video_core/memory_manager.h +++ b/src/video_core/memory_manager.h @@ -24,6 +24,10 @@ public: PAddr MapBufferEx(VAddr vaddr, PAddr paddr, u64 size); VAddr PhysicalToVirtualAddress(PAddr paddr); + static constexpr u64 PAGE_BITS = 16; + static constexpr u64 PAGE_SIZE = 1 << PAGE_BITS; + static constexpr u64 PAGE_MASK = PAGE_SIZE - 1; + private: boost::optional<PAddr> FindFreeBlock(u64 size, u64 align = 1); bool IsPageMapped(PAddr paddr); @@ -35,7 +39,7 @@ private: }; static constexpr u64 MAX_ADDRESS{0x10000000000ULL}; - static constexpr u64 PAGE_TABLE_BITS{14}; + static constexpr u64 PAGE_TABLE_BITS{10}; static constexpr u64 PAGE_TABLE_SIZE{1 << PAGE_TABLE_BITS}; static constexpr u64 PAGE_TABLE_MASK{PAGE_TABLE_SIZE - 1}; static constexpr u64 PAGE_BLOCK_BITS{14}; |