Moving Unpacked Entities from the Sim Region to World
?
?

Keyboard Navigation

Global Keys

[, < / ], > Jump to previous / next episode
W, K, P / S, J, N Jump to previous / next timestamp
t / T Toggle theatre / SUPERtheatre mode
V Revert filter to original state Y Select link (requires manual Ctrl-c)

Menu toggling

q Quotes r References f Filter y Link c Credits

In-Menu and Index Controls

a
w
s
d
h j k l


Esc Close menu / unfocus timestamp

Quotes and References Menus and Index

Enter Jump to timestamp

Quotes, References and Credits Menus

o Open URL (in new tab)

Filter Menu

x, Space Toggle category and focus next
X, ShiftSpace Toggle category and focus previous
v Invert topics / media as per focus

Filter and Link Menus

z Toggle filter / linking mode

Credits Menu

Enter Open URL (in new tab)
0:01Recap and set the stage for the day
🗩
0:01Recap and set the stage for the day
🗩
0:01Recap and set the stage for the day
🗩
1:10Demo our new memory viewer, with a view to working on the storage of our world's entity data
🏃
1:10Demo our new memory viewer, with a view to working on the storage of our world's entity data
🏃
1:10Demo our new memory viewer, with a view to working on the storage of our world's entity data
🏃
6:05Our entity system, not pre-designed
📖
6:05Our entity system, not pre-designed
📖
6:05Our entity system, not pre-designed
📖
8:10Compare the memory requirements of our entity system, with and without the ground_cover
🏃
🖮
8:10Compare the memory requirements of our entity system, with and without the ground_cover
🏃
🖮
8:10Compare the memory requirements of our entity system, with and without the ground_cover
🏃
🖮
8:55Our concrete problem: visual effects only need to be stored while they are visible
🗩
8:55Our concrete problem: visual effects only need to be stored while they are visible
🗩
8:55Our concrete problem: visual effects only need to be stored while they are visible
🗩
14:16Alternative, lossy representations of entities
🗩
14:16Alternative, lossy representations of entities
🗩
14:16Alternative, lossy representations of entities
🗩
17:31BeginSim() and the (un)packing of entities
📖
17:31BeginSim() and the (un)packing of entities
📖
17:31BeginSim() and the (un)packing of entities
📖
21:50Changing the sim_region to contain a reference table of entity pointers contained in the world's cache
📖
21:50Changing the sim_region to contain a reference table of entity pointers contained in the world's cache
📖
21:50Changing the sim_region to contain a reference table of entity pointers contained in the world's cache
📖
24:22Start to reacquaint ourselves with all uses of the sim_region's Entities
📖
24:22Start to reacquaint ourselves with all uses of the sim_region's Entities
📖
24:22Start to reacquaint ourselves with all uses of the sim_region's Entities
📖
26:40Reacquaint ourselves with the sim_region's EntityHashOccupancy
📖
26:40Reacquaint ourselves with the sim_region's EntityHashOccupancy
📖
26:40Reacquaint ourselves with the sim_region's EntityHashOccupancy
📖
28:20Continue to reacquaint ourselves with all uses of the sim_region's Entities
📖
28:20Continue to reacquaint ourselves with all uses of the sim_region's Entities
📖
28:20Continue to reacquaint ourselves with all uses of the sim_region's Entities
📖
29:29Augment the world struct with UnpackedEntities, into which the sim_region may point
29:29Augment the world struct with UnpackedEntities, into which the sim_region may point
29:29Augment the world struct with UnpackedEntities, into which the sim_region may point
37:04The problem of determining which entities to pack
📖
37:04The problem of determining which entities to pack
📖
37:04The problem of determining which entities to pack
📖
40:32Change all instances of entity array iteration in the sim region to operate as if on a reference table of pointers, introducing entity_iterator and IterateAllEntities()
40:32Change all instances of entity array iteration in the sim region to operate as if on a reference table of pointers, introducing entity_iterator and IterateAllEntities()
40:32Change all instances of entity array iteration in the sim region to operate as if on a reference table of pointers, introducing entity_iterator and IterateAllEntities()
45:45Begin to move all the existing entity storage, packing and unpacking code from the sim region to the world, introducing EnsureRegionIsUnpacked()
45:45Begin to move all the existing entity storage, packing and unpacking code from the sim region to the world, introducing EnsureRegionIsUnpacked()
45:45Begin to move all the existing entity storage, packing and unpacking code from the sim region to the world, introducing EnsureRegionIsUnpacked()
56:51Consider how to correctly set the origin of entities during unpacking
📖
56:51Consider how to correctly set the origin of entities during unpacking
📖
56:51Consider how to correctly set the origin of entities during unpacking
📖
1:02:42Augment the world with a world_position UnpackOrigin, for EnsureRegionIsUnpacked() to use, and introduce RegisterEntity()
1:02:42Augment the world with a world_position UnpackOrigin, for EnsureRegionIsUnpacked() to use, and introduce RegisterEntity()
1:02:42Augment the world with a world_position UnpackOrigin, for EnsureRegionIsUnpacked() to use, and introduce RegisterEntity()
1:10:55Introduce a version in the world of CreateEntity() that takes a world *
1:10:55Introduce a version in the world of CreateEntity() that takes a world *
1:10:55Introduce a version in the world of CreateEntity() that takes a world *
1:15:11Introduce RepackEntitiesAsNecessary() in the world, for the sim region's EndWorldChange() to call
1:15:11Introduce RepackEntitiesAsNecessary() in the world, for the sim region's EndWorldChange() to call
1:15:11Introduce RepackEntitiesAsNecessary() in the world, for the sim region's EndWorldChange() to call
1:24:57Implement IterateAllEntities() and the entity_iterator version of Advance(), introducing FindNextEntity()
1:24:57Implement IterateAllEntities() and the entity_iterator version of Advance(), introducing FindNextEntity()
1:24:57Implement IterateAllEntities() and the entity_iterator version of Advance(), introducing FindNextEntity()
1:30:58Hit our assertion in GetHashFromID()
🏃
1:30:58Hit our assertion in GetHashFromID()
🏃
1:30:58Hit our assertion in GetHashFromID()
🏃
1:31:30Fix BeginWorldChange() to call EnsureRegionIsUnpacked()
1:31:30Fix BeginWorldChange() to call EnsureRegionIsUnpacked()
1:31:30Fix BeginWorldChange() to call EnsureRegionIsUnpacked()
1:32:21Hit our InvalidCodePath in EnsureRegionIsUnpacked()
🏃
1:32:21Hit our InvalidCodePath in EnsureRegionIsUnpacked()
🏃
1:32:21Hit our InvalidCodePath in EnsureRegionIsUnpacked()
🏃
1:32:42Remove Entities_ from the sim_region, and fix EnsureRegionIsUnpacked() to operate on the entities in the world
1:32:42Remove Entities_ from the sim_region, and fix EnsureRegionIsUnpacked() to operate on the entities in the world
1:32:42Remove Entities_ from the sim_region, and fix EnsureRegionIsUnpacked() to operate on the entities in the world
1:33:28Hit our InvalidCodePath in EnsureRegionIsUnpacked(), and investigate why
🏃
1:33:28Hit our InvalidCodePath in EnsureRegionIsUnpacked(), and investigate why
🏃
1:33:28Hit our InvalidCodePath in EnsureRegionIsUnpacked(), and investigate why
🏃
1:36:15Augment the world with an UnpackIsOpen to prevent multiple concurrent unpacks of the same sim region
1:36:15Augment the world with an UnpackIsOpen to prevent multiple concurrent unpacks of the same sim region
1:36:15Augment the world with an UnpackIsOpen to prevent multiple concurrent unpacks of the same sim region
1:37:50Hit our InvalidCodePath in EnsureRegionIsUnpacked(), noting that entity (un)packing succeeds during world generation, but not during simulation
🏃
1:37:50Hit our InvalidCodePath in EnsureRegionIsUnpacked(), noting that entity (un)packing succeeds during world generation, but not during simulation
🏃
1:37:50Hit our InvalidCodePath in EnsureRegionIsUnpacked(), noting that entity (un)packing succeeds during world generation, but not during simulation
🏃
1:41:09Enable EnsureRegionIsUnpacked() to detect infinite looping
1:41:09Enable EnsureRegionIsUnpacked() to detect infinite looping
1:41:09Enable EnsureRegionIsUnpacked() to detect infinite looping
1:46:51Hit our InvalidCodePath in EnsureRegionIsUnpacked(), assuming that it is not infinite looping
🏃
1:46:51Hit our InvalidCodePath in EnsureRegionIsUnpacked(), assuming that it is not infinite looping
🏃
1:46:51Hit our InvalidCodePath in EnsureRegionIsUnpacked(), assuming that it is not infinite looping
🏃
1:47:17Investigate why we are hitting the InvalidCodePath in EnsureRegionIsUnpacked()
📖
1:47:17Investigate why we are hitting the InvalidCodePath in EnsureRegionIsUnpacked()
📖
1:47:17Investigate why we are hitting the InvalidCodePath in EnsureRegionIsUnpacked()
📖
1:51:57Step through many calls to RepackEntitiesAsNecessary(), watching the EntityP values
🏃
1:51:57Step through many calls to RepackEntitiesAsNecessary(), watching the EntityP values
🏃
1:51:57Step through many calls to RepackEntitiesAsNecessary(), watching the EntityP values
🏃
1:56:48Step through IterateAllEntities() to see that we do find stuff
🏃
1:56:48Step through IterateAllEntities() to see that we do find stuff
🏃
1:56:48Step through IterateAllEntities() to see that we do find stuff
🏃
1:58:36Step through EnsureRegionIsUnpacked(), watching which chunk is responsible for the majority of blocks
🏃
1:58:36Step through EnsureRegionIsUnpacked(), watching which chunk is responsible for the majority of blocks
🏃
1:58:36Step through EnsureRegionIsUnpacked(), watching which chunk is responsible for the majority of blocks
🏃
2:01:33Track our number of packs minus unpacks
2:01:33Track our number of packs minus unpacks
2:01:33Track our number of packs minus unpacks
2:04:28Find that the LastUsedEntityStorageIndex is 31 higher than our TotalEntityPacksMinusUnpacks
🏃
2:04:28Find that the LastUsedEntityStorageIndex is 31 higher than our TotalEntityPacksMinusUnpacks
🏃
2:04:28Find that the LastUsedEntityStorageIndex is 31 higher than our TotalEntityPacksMinusUnpacks
🏃
2:06:32Temporarily set a huge MAX_SIM_REGION_ENTITY_COUNT
2:06:32Temporarily set a huge MAX_SIM_REGION_ENTITY_COUNT
2:06:32Temporarily set a huge MAX_SIM_REGION_ENTITY_COUNT
2:08:41Step over BeginWorldChange() to find that we are trying to unpack 15383 entities, fewer than the LastUsedEntityStorageIndex of 21523
🏃
2:08:41Step over BeginWorldChange() to find that we are trying to unpack 15383 entities, fewer than the LastUsedEntityStorageIndex of 21523
🏃
2:08:41Step over BeginWorldChange() to find that we are trying to unpack 15383 entities, fewer than the LastUsedEntityStorageIndex of 21523
🏃
2:09:22Disable lighting
2:09:22Disable lighting
2:09:22Disable lighting
2:18:08Crash in LoadEntityReference()
🏃
2:18:08Crash in LoadEntityReference()
🏃
2:18:08Crash in LoadEntityReference()
🏃
2:19:14Make RepackEntitiesAsNecessary() take a SimRegion to pass to PackTraversableRefernce()
2:19:14Make RepackEntitiesAsNecessary() take a SimRegion to pass to PackTraversableRefernce()
2:19:14Make RepackEntitiesAsNecessary() take a SimRegion to pass to PackTraversableRefernce()
2:20:08Still crash in LoadEntityReference()
🏃
2:20:08Still crash in LoadEntityReference()
🏃
2:20:08Still crash in LoadEntityReference()
🏃
2:20:43Fix FindNextEntity() to only find an entity if its occupancy slot is not empty
🦉
🖮
2:20:43Fix FindNextEntity() to only find an entity if its occupancy slot is not empty
🦉
🖮
2:20:43Fix FindNextEntity() to only find an entity if its occupancy slot is not empty
🦉
🖮
2:23:48Run without crashing, but see that RepackEntitiesAsNecessary() is happening too often
🏃
🦉
2:23:48Run without crashing, but see that RepackEntitiesAsNecessary() is happening too often
🏃
🦉
2:23:48Run without crashing, but see that RepackEntitiesAsNecessary() is happening too often
🏃
🦉
2:25:23Step through BeginSim() to see a huge discrepancy between our TotalEntityPacksMinusUnpacks of 6109 and LastUsedEntityStorageIndex of 21523
🏃
🦉
2:25:23Step through BeginSim() to see a huge discrepancy between our TotalEntityPacksMinusUnpacks of 6109 and LastUsedEntityStorageIndex of 21523
🏃
🦉
2:25:23Step through BeginSim() to see a huge discrepancy between our TotalEntityPacksMinusUnpacks of 6109 and LastUsedEntityStorageIndex of 21523
🏃
🦉
2:26:36Scrutinise EnsureRegionIsUnpacked()
🦉
📖
2:26:36Scrutinise EnsureRegionIsUnpacked()
🦉
📖
2:26:36Scrutinise EnsureRegionIsUnpacked()
🦉
📖
2:27:58Fix EnsureRegionIsUnpacked() to offset the Dest->P after actually setting the Dest
🦉
🖮
2:27:58Fix EnsureRegionIsUnpacked() to offset the Dest->P after actually setting the Dest
🦉
🖮
2:27:58Fix EnsureRegionIsUnpacked() to offset the Dest->P after actually setting the Dest
🦉
🖮
2:28:13Find that everything now works, noting the performance of the game in debug mode without lighting
🏃
🦉
2:28:13Find that everything now works, noting the performance of the game in debug mode without lighting
🏃
🦉
2:28:13Find that everything now works, noting the performance of the game in debug mode without lighting
🏃
🦉
2:29:29Re-enable lighting
🦉
🖮
2:29:29Re-enable lighting
🦉
🖮
2:29:29Re-enable lighting
🦉
🖮
2:30:01Find that we are fully back to normal
🏃
🦉
2:30:01Find that we are fully back to normal
🏃
🦉
2:30:01Find that we are fully back to normal
🏃
🦉
2:30:56Q&A
🗩
2:30:56Q&A
🗩
2:30:56Q&A
🗩
2:32:00somebody_took_my_name Q: Will the packed entity be a separate struct, and what is the plan of adding / removing data?
🗪
2:32:00somebody_took_my_name Q: Will the packed entity be a separate struct, and what is the plan of adding / removing data?
🗪
2:32:00somebody_took_my_name Q: Will the packed entity be a separate struct, and what is the plan of adding / removing data?
🗪
2:34:07Brian Q: I had a question regarding the Arena graph in the profiler, though it may have changed this episode, and you may not be able to display it in its current state. It was about why there were separations between the ground chunks (the first group, all were "green", but every X amount, there was a gray value that separated them). What was this separation?
🗪
2:34:07Brian Q: I had a question regarding the Arena graph in the profiler, though it may have changed this episode, and you may not be able to display it in its current state. It was about why there were separations between the ground chunks (the first group, all were "green", but every X amount, there was a gray value that separated them). What was this separation?
🗪
2:34:07Brian Q: I had a question regarding the Arena graph in the profiler, though it may have changed this episode, and you may not be able to display it in its current state. It was about why there were separations between the ground chunks (the first group, all were "green", but every X amount, there was a gray value that separated them). What was this separation?
🗪
2:37:41Remove the cruft from world_entity_block
2:37:41Remove the cruft from world_entity_block
2:37:41Remove the cruft from world_entity_block
2:39:15Check out our more closely packed entity blocks
🏃
2:39:15Check out our more closely packed entity blocks
🏃
2:39:15Check out our more closely packed entity blocks
🏃
2:41:31Change CreateWorld() to put the world in its own memory arena, noting that GetWorldChunk() allocates space for the headers
2:41:31Change CreateWorld() to put the world in its own memory arena, noting that GetWorldChunk() allocates space for the headers
2:41:31Change CreateWorld() to put the world in its own memory arena, noting that GetWorldChunk() allocates space for the headers
2:44:03See that our entity blocks are packed the same
🏃
2:44:03See that our entity blocks are packed the same
🏃
2:44:03See that our entity blocks are packed the same
🏃
2:44:24Revert CreateWorld() to put the world in the GameState->ModeArena
2:44:24Revert CreateWorld() to put the world in the GameState->ModeArena
2:44:24Revert CreateWorld() to put the world in the GameState->ModeArena
2:44:47Note the utility of memory usage visualisation
🏃
2:44:47Note the utility of memory usage visualisation
🏃
2:44:47Note the utility of memory usage visualisation
🏃
2:45:05Change GetWorldChunk() to allocate space for chunks in bulk
2:45:05Change GetWorldChunk() to allocate space for chunks in bulk
2:45:05Change GetWorldChunk() to allocate space for chunks in bulk
2:49:29Check out our perfectly packed entity blocks
🏃
2:49:29Check out our perfectly packed entity blocks
🏃
2:49:29Check out our perfectly packed entity blocks
🏃
2:51:20sourdust Q: Did you ever figure out MEM_LARGE_PAGES for VirtualAlloc? Is that what you're talking about?
🗪
2:51:20sourdust Q: Did you ever figure out MEM_LARGE_PAGES for VirtualAlloc? Is that what you're talking about?
🗪
2:51:20sourdust Q: Did you ever figure out MEM_LARGE_PAGES for VirtualAlloc? Is that what you're talking about?
🗪
2:51:35centhusiast Q: How did people do memory management in the era of Commodore 64 for writing games? It is so luxurious nowadays with all these amounts of memory we have on our machines
🗪
2:51:35centhusiast Q: How did people do memory management in the era of Commodore 64 for writing games? It is so luxurious nowadays with all these amounts of memory we have on our machines
🗪
2:51:35centhusiast Q: How did people do memory management in the era of Commodore 64 for writing games? It is so luxurious nowadays with all these amounts of memory we have on our machines
🗪
2:53:39Close this down for today
🗩
2:53:39Close this down for today
🗩
2:53:39Close this down for today
🗩