|
|
|
|
|
by flohofwoe
1103 days ago
|
|
I haven't seen such dramatic speedups in my own code for quite a while since I don't tend to start with a worst case version. With some googling it's easy to find cases like this where switching from a traditional OOP approach of "unique objects in random heap locations" to a DOD approach gains a 173x speedup overall (it's not just the tight memory layout of course, but also all the code simplifications this enables, like tighter loops and then easier integration of multithreading): https://medium.com/@jasonbooth_86226/intro-to-jobs-burst-dod... Basically, search for DOD (Data Oriented Design), ECS (Entity Component System), SoA (Structure of Arrays) for similar optimization stories. |
|