mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-04 06:54:33 +00:00
Remove gSystemHeap and use _buffersSegmentEnd instead, make buffer alignments explicit for gcc (#1901)
* Remove gSystemHeap and use _buffersSegmentEnd instead, make buffer alignments explicit for gcc * ALIGNEDn -> ALIGNED(n), reposition alignment attribute for PreNmiBuff * Correct positioning of ALIGNED for filter data in audio/lib/data.c * Add ALIGNED to TypenameMacros * ALIGNED(4) on same line for PreNmiBuff * Revert audio load.c change, to be submitted separately
This commit is contained in:
parent
6e2ea18154
commit
c521f1f8ae
16 changed files with 45 additions and 40 deletions
|
@ -1,6 +1,8 @@
|
|||
#include "global.h"
|
||||
#include "terminal.h"
|
||||
|
||||
extern u8 _buffersSegmentEnd[];
|
||||
|
||||
s32 gScreenWidth = SCREEN_WIDTH;
|
||||
s32 gScreenHeight = SCREEN_HEIGHT;
|
||||
u32 gSystemHeapSize = 0;
|
||||
|
@ -29,7 +31,8 @@ OSMesg sSerialMsgBuf[1];
|
|||
void Main_LogSystemHeap(void) {
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "System heap size% 08x (% dKB) Start address% 08x"
|
||||
PRINTF("システムヒープサイズ %08x(%dKB) 開始アドレス %08x\n", gSystemHeapSize, gSystemHeapSize / 1024, gSystemHeap);
|
||||
PRINTF("システムヒープサイズ %08x(%dKB) 開始アドレス %08x\n", gSystemHeapSize, gSystemHeapSize / 1024,
|
||||
_buffersSegmentEnd);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
#endif
|
||||
|
@ -48,7 +51,7 @@ void Main(void* arg) {
|
|||
PreNmiBuff_Init(gAppNmiBufferPtr);
|
||||
Fault_Init();
|
||||
SysCfb_Init(0);
|
||||
systemHeapStart = (uintptr_t)gSystemHeap;
|
||||
systemHeapStart = (uintptr_t)_buffersSegmentEnd;
|
||||
fb = (uintptr_t)SysCfb_GetFbPtr(0);
|
||||
gSystemHeapSize = fb - systemHeapStart;
|
||||
// "System heap initalization"
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
#include "global.h"
|
||||
|
||||
// The use of ALIGNED8 here is just a temporary solution until the SaveContext is re-structured
|
||||
ALIGNED8 SaveContext gSaveContext;
|
||||
ALIGNED(16) SaveContext gSaveContext;
|
||||
u32 D_8015FA88;
|
||||
u32 D_8015FA8C;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue