Adaptive Hashing: Faster Hash Functions with Fewer Collisions
G\'abor Melis

TL;DR
This paper introduces an adaptive hash function approach that dynamically adjusts to the current set of keys, improving performance and reducing collisions in hash tables without changing the API.
Contribution
It proposes a novel online adaptive hashing method that balances speed and collision reduction, outperforming fixed and traditional hash functions.
Findings
Adaptive hashing improves bucketing efficiency.
Reduces hash collisions compared to fixed hash functions.
Maintains low overhead with no API changes.
Abstract
Hash tables are ubiquitous, and the choice of hash function, which maps a key to a bucket, is key to their performance. We argue that the predominant approach of fixing the hash function for the lifetime of the hash table is suboptimal and propose adapting it to the current set of keys. In the prevailing view, good hash functions spread the keys ``randomly'' and are fast to evaluate. General-purpose ones (e.g. Murmur) are designed to do both while remaining agnostic to the distribution of the keys, which limits their bucketing ability and wastes computation. When these shortcomings are recognized, one may specify a hash function more tailored to some assumed key distribution, but doing so almost always introduces an unbounded risk in case this assumption does not bear out in practice. At the other, fully key-aware end of the spectrum, Perfect Hashing algorithms can discover hash…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsAdvanced Image and Video Retrieval Techniques · Caching and Content Delivery · Network Packet Processing and Optimization
