Optimize the Data Layout

by napsterbron 10/11/2024, 12:54 PMwith 7 comments

by o11con 10/15/2024, 8:48 PM

Where this gets interesting is when you have patterns of sparse data. Often a mix is best - AoS fails badly for partially-sparse rows, and SoA requires duplicating the key, but SoAoS only has to duplicate the key per struct, and SoAoSoA only has to duplicate it once per sequence of adjacent structs.

by jakozauron 10/15/2024, 6:32 PM

A similar explanation could be applied to columnar vs row databases.