is presently its sole maintainer,
You can support him:
Recap and set the stage for the day
Run the game to see that we are still running and can do looped live code editing
handmade_memory.h: Determine to provoke some deleterious effects
handmade_platform.h: Replace TransientStorage with a TransientState
handmade.cpp: Enable DEBUGGetMainGeneration() to initialise a TransientState
handmade_memory.h: Introduce BootstrapPushSize_() and BootstrapPushStruct() for all of the transient arena initialisation sites to use
Run the game and crash in EndTemporaryMemory()
Blackboard: Temporary Memory for Dynamic Arenas
handmade_memory.h: Introduce memory_block_footer struct and GetFooter() and make PushSize_() stick that footer onto the end of blocks
handmade_memory.h: Add Base to the temporary_memory struct to enable EndTemporaryMemory() to loop back over the blocks, and introduce FreeLastBlock()
Run the game to see that we're totally running as we were before
Consult perfmon to verify that we're not leaking memory
Switch over the entire codebase to run through dynamic allocation
Run the game successfully
handmade_memory.h: Enable Clear() to handle dynamically allocated blocks
handmade_world.h: Make all modes use the arena they're given rather than sub-allocating out of it
4coder feature: Stream mode
Run the game to see that our poor cutscene is gone
Reflect on our first part of the memory upgrade
todo.txt: Update the TODO list
zilarrezko Q: Have you ever tried reserving a very large amount of memory, and then committing memory as needed, so the arena can grow without the base pointer changing?
dudeinbasement1 Q: Thoughts on placing the "footer", at the beginning of the memory area, so bad co-workers don't overwrite it (because it is at the end currently)
m1el Q: You spend so much time on memory management. If programming games for windows / Linux would it be better to use malloc and then create custom allocation for hot parts?
billdstrong Q: Casey, how strict are you on minimizing the amount of memory is used by the game?
sssmcgrath Q: Your article didn't even touch on the horrors of ETW. I had to manually fill out several GUIDs that msft decided not to include in their headers for some reason by pulling them off three different, very obscure MSDN pages that were auto generated for C# markup. I had to reverse engineer several void * pointers by using partial data on MSDN and inspecting the memory and guessing sizes, offsets and types. There was a variable listed on MSDN as "object UserSID"... Yes, the type was "object", and guess what! It's not a SID, it's 2 unknown / undocumented pointers then a SID! What are those pointers? Who knows. They also intermixed ASCII and UTF16 strings, one after the other with no documentation... Yay!
Miblo Q: When we're dynamically allocating, we could potentially end up allocating every last drop of memory available to us, right? Are there situations in which we'd want to make sure we allocate "some amount" less than the max and, if so, how would we best do that?
longboolean Q: So currently you can only free memory in the last memory blocks? If you wanted to free stuff near the beginning of the arena and keep the stuff at the end, you would need to do things differently?
zilarrezko Q: If you are planning on large worlds, are you planning then on compressing and decompressing from the mandala on the fly?
m1el Q: Will Handmade Hero use texture compression in OpenGL?
pseudonym73 Q: The term "arena" refers to a region of memory from which multiple objects are allocated and which can be deallocated all at once. Some arenas support object freeing, some do not