JayWalker512 / Game_of_Life

Multi-threaded Conway's Game of Life written in C with OpenGL graphics
MIT License
2 stars 0 forks source link

Implement cell state with bits instead of bytes #5

Open JayWalker512 opened 7 years ago

JayWalker512 commented 7 years ago

Doesn't need much description. One byte can hold 8 cell states, and would make the whole world array smaller by a factor of 8. Further improvements made from this might be "regions" fixed at 8x8 so that a block being simulated would fit in a handful of CPU registers. If these regions could be made so that each row is contiguous, this would further improve speed by taking advantage of spacial locality.