summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDrChat <arkolbed@gmail.com>2018-02-10 16:45:06 -0600
committerDrChat <arkolbed@gmail.com>2018-02-10 16:45:06 -0600
commit4db94473ec5095538b250a2c1f0f75a2f85e9b60 (patch)
tree41f3cd8fd0da6ddb89028695eb426fb6ced900f6
parent5a637d6899607e0085aade33ff0889d348b62e93 (diff)
[Core] Memory::GetPhysicalHeap
-rw-r--r--src/xenia/memory.cc2
-rw-r--r--src/xenia/memory.h3
2 files changed, 5 insertions, 0 deletions
diff --git a/src/xenia/memory.cc b/src/xenia/memory.cc
index 5461f027a..221f97362 100644
--- a/src/xenia/memory.cc
+++ b/src/xenia/memory.cc
@@ -337,6 +337,8 @@ BaseHeap* Memory::LookupHeapByType(bool physical, uint32_t page_size) {
}
}
+VirtualHeap* Memory::GetPhysicalHeap() { return &heaps_.physical; }
+
void Memory::Zero(uint32_t address, uint32_t size) {
std::memset(TranslateVirtual(address), 0, size);
}
diff --git a/src/xenia/memory.h b/src/xenia/memory.h
index 7ca057a1d..74f5f9568 100644
--- a/src/xenia/memory.h
+++ b/src/xenia/memory.h
@@ -332,6 +332,9 @@ class Memory {
// Gets the heap with the given properties.
BaseHeap* LookupHeapByType(bool physical, uint32_t page_size);
+ // Gets the physical base heap.
+ VirtualHeap* GetPhysicalHeap();
+
// Dumps a map of all allocated memory to the log.
void DumpMap();