system_malloc OK (#261)

* move system_malloc to boot_O2

* Rename StartHeap into SystemArena

* match

* fake system_malloc data

* fix return types

* Rename Alloc to Malloc

* Update tools/disasm/files.txt

Co-authored-by: EllipticEllipsis <73679967+EllipticEllipsis@users.noreply.github.com>

* fix spec

Co-authored-by: EllipticEllipsis <73679967+EllipticEllipsis@users.noreply.github.com>
This commit is contained in:
Anghelo Carvajal
2021-08-18 08:48:08 -04:00
committed by GitHub
parent 9eb438860c
commit 49922b4856
12 changed files with 88 additions and 60 deletions
+1 -1
View File
@@ -170,7 +170,7 @@ void Game_ResizeHeap(GameState* gamestate, u32 size) {
alloc = &gamestate->alloc;
THA_Dt(&gamestate->heap);
Gamealloc_Free(alloc, heapStart);
StartHeap_AnalyzeArena(&systemMaxFree, &bytesFree, &bytesAllocated);
SystemArena_AnalyzeArena(&systemMaxFree, &bytesFree, &bytesAllocated);
size = ((systemMaxFree - (sizeof(ArenaNode))) < size) ? (0) : (size);
if (!size) {
size = systemMaxFree - (sizeof(ArenaNode));