diff options
| author | 2017-10-22 23:17:59 -0400 | |
|---|---|---|
| committer | 2017-10-22 23:17:59 -0400 | |
| commit | 9ceb0d93817c1dd48c954bfdbb7516fc3d913245 (patch) | |
| tree | 137f1c884c66412d6addb026ef4f52c141ca4a07 /src | |
| parent | hle: Fix QueryMemory response for MemoryInfo. (diff) | |
| download | yuzu-9ceb0d93817c1dd48c954bfdbb7516fc3d913245.tar.gz yuzu-9ceb0d93817c1dd48c954bfdbb7516fc3d913245.tar.xz yuzu-9ceb0d93817c1dd48c954bfdbb7516fc3d913245.zip | |
memory: Support 32-bit paging, move heap address space up.
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/loader/nso.cpp | 2 | ||||
| -rw-r--r-- | src/core/memory.h | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/core/loader/nso.cpp b/src/core/loader/nso.cpp index 0d16d4b8c..7b44d452e 100644 --- a/src/core/loader/nso.cpp +++ b/src/core/loader/nso.cpp | |||
| @@ -163,7 +163,7 @@ ResultStatus AppLoader_NSO::Load(Kernel::SharedPtr<Kernel::Process>& process) { | |||
| 163 | 163 | ||
| 164 | // Load and relocate remaining submodules | 164 | // Load and relocate remaining submodules |
| 165 | for (const auto& module_name : {"main", "sdk", "subsdk0", "subsdk1"}) { | 165 | for (const auto& module_name : {"main", "sdk", "subsdk0", "subsdk1"}) { |
| 166 | LOG_INFO(Loader, "loading %s @ 0x%08x", module_name, next_base_addr); | 166 | LOG_INFO(Loader, "loading %s @ 0x%llx", module_name, next_base_addr); |
| 167 | const std::string module_path = | 167 | const std::string module_path = |
| 168 | filepath.substr(0, filepath.find_last_of("/\\")) + "/" + module_name; | 168 | filepath.substr(0, filepath.find_last_of("/\\")) + "/" + module_name; |
| 169 | next_base_addr = LoadNso(module_path, next_base_addr); | 169 | next_base_addr = LoadNso(module_path, next_base_addr); |
diff --git a/src/core/memory.h b/src/core/memory.h index 9a04b9a16..8c60f1dd3 100644 --- a/src/core/memory.h +++ b/src/core/memory.h | |||
| @@ -26,7 +26,7 @@ namespace Memory { | |||
| 26 | const int PAGE_BITS = 12; | 26 | const int PAGE_BITS = 12; |
| 27 | const u64 PAGE_SIZE = 1 << PAGE_BITS; | 27 | const u64 PAGE_SIZE = 1 << PAGE_BITS; |
| 28 | const u64 PAGE_MASK = PAGE_SIZE - 1; | 28 | const u64 PAGE_MASK = PAGE_SIZE - 1; |
| 29 | const size_t PAGE_TABLE_NUM_ENTRIES = 1ULL << (32 - PAGE_BITS); | 29 | const size_t PAGE_TABLE_NUM_ENTRIES = 1ULL << (36 - PAGE_BITS); |
| 30 | 30 | ||
| 31 | enum class PageType { | 31 | enum class PageType { |
| 32 | /// Page is unmapped and should cause an access error. | 32 | /// Page is unmapped and should cause an access error. |
| @@ -135,7 +135,7 @@ enum : VAddr { | |||
| 135 | IPC_MAPPING_VADDR_END = IPC_MAPPING_VADDR + IPC_MAPPING_SIZE, | 135 | IPC_MAPPING_VADDR_END = IPC_MAPPING_VADDR + IPC_MAPPING_SIZE, |
| 136 | 136 | ||
| 137 | /// Application heap (includes stack). | 137 | /// Application heap (includes stack). |
| 138 | HEAP_VADDR = 0x08000000, | 138 | HEAP_VADDR = 0x108000000, |
| 139 | HEAP_SIZE = 0x08000000, | 139 | HEAP_SIZE = 0x08000000, |
| 140 | HEAP_VADDR_END = HEAP_VADDR + HEAP_SIZE, | 140 | HEAP_VADDR_END = HEAP_VADDR + HEAP_SIZE, |
| 141 | 141 | ||