A generic hash table
A generic hash table
Posted Aug 10, 2012 16:28 UTC (Fri) by nix (subscriber, #2304)In reply to: A generic hash table by nybble41
Parent article: A generic hash table
Yeah. There are hash designs which don't have this problem -- e.g. any based on trees (you can even arrange that deletion of the key you're currently iterating over will only impose the same overhead on the next iteration as a normal hash lookup). Downside: trees often involve a lot of pointer chasing, and some of them are write-heavy on update and even on read (e.g. splay trees: nice self-optimizing data structure, shame about your cacheline contention).
