mirror of
https://gitlab.com/ryandwyer/perfect-dark
synced 2026-08-09 02:26:10 -04:00
Place game segment after bss to make more room for memp
This commit is contained in:
@@ -245,6 +245,7 @@ SECTIONS
|
||||
*/
|
||||
|
||||
__savedrompos = __rompos;
|
||||
__savedrampos = __rampos;
|
||||
__rampos = 0x80200000;
|
||||
__rompos = _datazipSegmentRomEnd;
|
||||
|
||||
@@ -269,7 +270,7 @@ SECTIONS
|
||||
PLACEHOLDER_SEGMENT(gamezip, ROMALLOCATION_GAME)
|
||||
|
||||
__rompos = __savedrompos;
|
||||
__rampos = 0x80240000;
|
||||
__rampos = __savedrampos;
|
||||
|
||||
BEGIN_SEG(game)
|
||||
{
|
||||
|
||||
+2
-2
@@ -237,7 +237,7 @@ extern u8 _accessingpakSegmentRomStart;
|
||||
extern u8 _accessingpakSegmentRomEnd;
|
||||
extern u8 _copyrightSegmentRomStart;
|
||||
extern u8 _copyrightSegmentRomEnd;
|
||||
extern u8 _bssSegmentEnd;
|
||||
extern u8 _gameSegmentEnd;
|
||||
|
||||
#if VERSION >= VERSION_NTSC_1_0
|
||||
/**
|
||||
@@ -459,7 +459,7 @@ void mainInit(void)
|
||||
argSetString(" -ml0 -me0 -mgfx100 -mvtx50 -mt700 -ma400");
|
||||
}
|
||||
|
||||
start = (u8 *) PHYS_TO_K0(osVirtualToPhysical(&_bssSegmentEnd));
|
||||
start = (u8 *) PHYS_TO_K0(osVirtualToPhysical(&_gameSegmentEnd));
|
||||
end = g_VmMarker;
|
||||
mempSetHeap(start, end - start);
|
||||
|
||||
|
||||
+2
-2
@@ -813,10 +813,10 @@ void vmInit(void)
|
||||
s7 = (u8 *)(STACK_START - 8);
|
||||
|
||||
// 0x803c0000 - (_gameSegmentLen aligned to 0x20000)
|
||||
gameseg = (u8 *) 0x80240000;
|
||||
gameseg = (u8 *) &_gameSegmentStart;
|
||||
|
||||
s5 = (u32 *) (((u32) gameseg - ((t8 + 5) << 2)) & ~0xf);
|
||||
g_VmMarker = (u8 *) 0x80240000;
|
||||
g_VmMarker = (u8 *) s7;
|
||||
sp1474 = t8 + 1;
|
||||
|
||||
// Load gamezips pointer list
|
||||
|
||||
Reference in New Issue
Block a user