3 ms·
This may be more about the indexing strategy than the hash function. Meaning: once we have the hash(es), how do we decide what index to use for the key? Open-a
by vlmutolo 3y ago
This may be more about the indexing strategy than the hash function. Meaning: once we have the hash(es), how do we decide what index to use for the key?
Open-addressing schemes like linear probing, quadratic probing, certain variants of Robinhood hashing (which is kind of on a different axis anyway) commonly have 50–70% expected space efficiency. Performance is bad above 90%.
But Cuckoo hash tables can get above 90% with great lookup performance (non-amortized constant time) and decent insert performance. Insert performance tends to suffer closer to 100%.
Whether or not cuckoo hash tables qualify as “open addressing” will depend on the implementation, but the main point is that the addressing/indexing strategy mainly determines the operable “load factor” of the hash table.
This is a great article on open addressing schemes (including cuckoo):
https://thenumb.at/Hashtables/ https://thenumb.at/Hashtables/