4 ms·
> * You can choose to use handles smaller than a pointer. Did you measure any performance improvements due to using small handles? I have a medium-sized proje
by muldvarp 3y ago
> * You can choose to use handles smaller than a pointer.
Did you measure any performance improvements due to using small handles?
I have a medium-sized project that uses a ton of `usize`s to reference elements in `Vec`s and would love to know if there's some potential for performance improvements there.
- burntsushi 3y agoIn this particular program I didn't do an in depth performance comparison because it wasn't really the point of the exercise. But in the actual regex crate, I do indeed use `u32` as a representation for a handle. To a first approximation, it corresponds to about half as much memory usage. Same deal with the aho-corasick crate.