aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/kernel/physical_memory.h
diff options
context:
space:
mode:
authorFernando Sahmkow <fsahmkow27@gmail.com>2019-07-18 18:15:53 -0400
committerFernandoS27 <fsahmkow27@gmail.com>2019-07-19 10:06:08 -0400
commit9bede4eeed523f9707a989f1297279c006086e76 (patch)
tree2acfabeff5f7f449bcdb22563f5ad66f7fa5f414 /src/core/hle/kernel/physical_memory.h
parent5d369112d9d467d4257e24ce57f3ebba824556f0 (diff)
VM_Manager: Align allocated memory to 256bytes
This commit ensures that all backing memory allocated for the Guest CPU is aligned to 256 bytes. This due to how gpu memory works and the heavy constraints it has in the alignment of physical memory.
Diffstat (limited to 'src/core/hle/kernel/physical_memory.h')
-rw-r--r--src/core/hle/kernel/physical_memory.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/core/hle/kernel/physical_memory.h b/src/core/hle/kernel/physical_memory.h
new file mode 100644
index 000000000..dd49c75a2
--- /dev/null
+++ b/src/core/hle/kernel/physical_memory.h
@@ -0,0 +1,13 @@
+// Copyright 2019 yuzu Emulator Project
+// Licensed under GPLv2 or any later version
+// Refer to the license.txt file included.
+
+#pragma once
+
+#include "common/alignment.h"
+
+namespace Kernel {
+
+using PhysicalMemory = std::vector<u8, Common::AlignmentAllocator<u8, 256>>;
+
+}