Re:Things you can’t do in Rust (and what to do instead)
by atq2119 on Sunday May 16, 2021 @01:09AM
(#27171371)
That's true. And there is seriously optimized software out there using linked lists (e.g. in the Linux kernel).
However, with bigger data in my experience a very good solution is often to have a vector of pointers to the actual data. This loses some locality of course, but during traversal the fact that you don't have dependencies between iterations can still be a win.
However, with bigger data in my experience a very good solution is often to have a vector of pointers to the actual data. This loses some locality of course, but during traversal the fact that you don't have dependencies between iterations can still be a win.