Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Primary caching 2: Introduce
FlatVecDeque
(#4593)
Introduce `FlatVecDeque` (feel free to rename), the core datastructure behind the primary cache. You can view it as a "native", circular `ListArray`: it's a flattened array of arrays, implemented as two ringbuffers, that stores actual components (i.e. deserialized data) in a cache friendly way. Also plenty of APIs to get data in and out, in and out of order. Once again, these benchmarks are disabled on CI. Some numbers for posterity / git log (5950X, Arch): ``` flat_vec_deque/insert/empty 1.00 310.9±3.87ns 3.0 GElem/sec flat_vec_deque/insert/prefilled/back 1.00 28.6±0.20µs 33.4 MElem/sec flat_vec_deque/insert/prefilled/front 1.00 29.1±0.17µs 32.7 MElem/sec flat_vec_deque/insert/prefilled/middle 1.00 42.8±0.57µs 22.3 MElem/sec flat_vec_deque/insert_range/empty 1.00 3.5±0.04µs 1348.1 MElem/sec flat_vec_deque/insert_range/prefilled/back 1.00 31.9±0.20µs 149.4 MElem/sec flat_vec_deque/insert_range/prefilled/front 1.00 30.6±0.17µs 155.7 MElem/sec flat_vec_deque/insert_range/prefilled/middle 1.00 46.3±0.20µs 102.9 MElem/sec flat_vec_deque/insert_with/empty 1.00 1375.4±43.80ns 3.4 GElem/sec flat_vec_deque/insert_with/prefilled/back 1.00 30.1±0.16µs 158.6 MElem/sec flat_vec_deque/insert_with/prefilled/front 1.00 27.8±0.83µs 171.5 MElem/sec flat_vec_deque/insert_with/prefilled/middle 1.00 44.8±0.34µs 106.4 MElem/sec flat_vec_deque/range/prefilled/back 1.00 15.3±0.05µs 312.3 MElem/sec flat_vec_deque/range/prefilled/front 1.00 15.8±0.15µs 301.2 MElem/sec flat_vec_deque/range/prefilled/middle 1.00 14.8±0.09µs 323.2 MElem/sec flat_vec_deque/remove/prefilled/back 1.00 14.4±0.07µs 67.8 KElem/sec flat_vec_deque/remove/prefilled/front 1.00 28.5±0.28µs 34.2 KElem/sec flat_vec_deque/remove/prefilled/middle 1.00 28.5±0.11µs 34.3 KElem/sec flat_vec_deque/remove_range/prefilled/back 1.00 14.6±0.07µs 326.0 MElem/sec flat_vec_deque/remove_range/prefilled/front 1.00 28.6±0.16µs 166.7 MElem/sec flat_vec_deque/remove_range/prefilled/middle 1.00 29.3±0.17µs 162.8 MElem/sec ``` --- Part of the primary caching series of PR (index search, joins, deserialization): - #4592 - #4593
- Loading branch information