mirror of
https://github.com/zeldaret/mm.git
synced 2026-08-08 02:30:14 -04:00
Move the system heap and the framebuffers to their own segments (#1488)
* make segments for the systemheap and the framebuffers * define in the makefile * undefined syms * Make segments for the pre boot buffers too * Update spec Co-authored-by: Parker <20159000+jpburnett@users.noreply.github.com> * review * Update spec Co-authored-by: Parker <20159000+jpburnett@users.noreply.github.com> * Update Makefile Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * comments * comment * move comment about the hardcoded address to buffers.h * rewrite SYSTEM_HEAP_END_ADDR in terms of other symbols * Use `ALIGNED` on all the buffers * Rename SYSTEM_HEAP_END_ADDR to FRAMEBUFFERS_START_ADDR * Put ALIGNED at the right like the rest of the codebase * merge * gLoBuffer * gHiBuffer * Add a static assert to ensure the address of gHiBuffer haven't shifted without the user noticing * smol include cleanup --------- Co-authored-by: Parker <20159000+jpburnett@users.noreply.github.com> Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
#include "buffers.h"
|
||||
|
||||
u8 gAudioHeap[0x138000] ALIGNED(16);
|
||||
@@ -0,0 +1,5 @@
|
||||
#include "buffers.h"
|
||||
|
||||
// Don't add symbols here unless you know what you are doing.
|
||||
|
||||
BufferHigh gHiBuffer ALIGNED(64);
|
||||
@@ -0,0 +1,5 @@
|
||||
#include "buffers.h"
|
||||
|
||||
// Don't add symbols here unless you know what you are doing.
|
||||
|
||||
BufferLow gLoBuffer ALIGNED(64);
|
||||
@@ -1,3 +1,3 @@
|
||||
#include "buffers.h"
|
||||
|
||||
GfxPool gGfxPools[2];
|
||||
GfxPool gGfxPools[2] ALIGNED(16);
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
#include "buffers.h"
|
||||
|
||||
STACK(gGfxSPTaskStack, 0x400);
|
||||
STACK(gGfxSPTaskStack, 0x400) ALIGNED(16);
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
#include "buffers.h"
|
||||
|
||||
u8 gGfxSPTaskYieldBuffer[OS_YIELD_DATA_SIZE];
|
||||
u8 gGfxSPTaskYieldBuffer[OS_YIELD_DATA_SIZE] ALIGNED(16);
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
#include "buffers.h"
|
||||
|
||||
u8 gAudioHeap[0x138000];
|
||||
|
||||
u8 gSystemHeap[UNK_SIZE];
|
||||
@@ -0,0 +1,6 @@
|
||||
#include "buffers.h"
|
||||
|
||||
// Don't add symbols here unless you know what you are doing.
|
||||
|
||||
// Dummy, marks the start of system_heap space whose actual size depends on the spec
|
||||
u8 gSystemHeap[UNK_SIZE] ALIGNED(16);
|
||||
Reference in New Issue
Block a user