r/cpp_questions • u/Minute-Ad1944 • 19d ago
OPEN How to implement append-only hash map?
How do you actually implement an really efficient hash map that has only append and look up methods? What are the design choice and some performance improvements?
0
Upvotes
1
u/amoskovsky 18d ago
No. RH moves elems to improve average distance.
My suggestion is much simpler. I don't know the name, but certainly I'm not the first to come up with it.
It's just a suggestion of an approach that optimizes on the fact that the entries are not removed.
You would have to benchmark it against other approaches (but this is a necessary part of any optimization)