temp arena change that lets us bypass memory decommits

This commit is contained in:
Nikita Smith
2024-10-15 14:43:36 -07:00
parent 65b5176468
commit 7e98df22d7
2 changed files with 62 additions and 11 deletions
+9 -1
View File
@@ -7,7 +7,11 @@
////////////////////////////////
//~ rjf: Constants
#define ARENA_HEADER_SIZE 64
#if ARENA_FREE_LIST
# define ARENA_HEADER_SIZE 128
#else
# define ARENA_HEADER_SIZE 64
#endif
////////////////////////////////
//~ rjf: Types
@@ -40,6 +44,10 @@ struct Arena
U64 pos;
U64 cmt;
U64 res;
#if ARENA_FREE_LIST
U64 free_size;
Arena *free_last;
#endif
};
StaticAssert(sizeof(Arena) <= ARENA_HEADER_SIZE, arena_header_size_check);