Locality in Open Addressing Hash Tables

📅 2026-07-17
📈 Citations: 0
Influential: 0
📄 PDF
🤖 AI Summary
This study addresses the joint optimization of probe complexity and locality—defined as the maximum geometric distance between accessed memory cells—in open-addressing hash tables. Recognizing the inherent trade-off between linear probing and uniform probing, which struggle to balance both objectives, we first establish a theoretical lower bound of $\Omega(1/\varepsilon^2)$ on locality for any load factor $1-\varepsilon$. We then propose two algorithms: one achieving near-optimal $\tilde{O}(1/\varepsilon)$ bounds on both probe count and locality when the target load is known, and another greedy strategy that operates without prior knowledge of the load. Additionally, we prove that fixed-offset probing sequences yield an expected probe complexity of $O(\log n / \varepsilon^2)$ under arbitrary loads. Our analysis combines probabilistic methods, variance-based density bounds, and amortized techniques to establish matching upper and lower bounds for this problem.
📝 Abstract
Open-addressed hash tables without reordering, such as linear probing and uniform probing, are among the simplest and most widely used data structures. Their performance is traditionally measured by probe count. We study a complementary parameter: locality, defined as the geometric distance from the first probed location to the farthest cell inspected or used. At load factor $1-\varepsilon$, uniform probing achieves the optimal $Θ(1/\varepsilon)$ probe count among greedy schemes, but has essentially no locality, whereas linear probing is highly local but performs $Θ(1/\varepsilon^2)$ probes. We show that this quadratic locality scale is fundamental: no open-addressing algorithm without reordering can achieve locality $o(1/\varepsilon^2)$ simultaneously at every load $1-\varepsilon$. We also prove an amortized expected-locality lower bound of $Ω(1/\varepsilon)$ over any sequence of $(1-\varepsilon)n$ insertions, even when the final load is known in advance. Our lower bound further implies that page size $B=Ω(1/\varepsilon^2)$ is necessary for $1+o(1)$ expected page span in immutable open addressing. We complement these lower bounds with two upper bounds. When the target load is known in advance, every insertion and every successful or unsuccessful search can be given expected probe count and locality $\widetilde O(1/\varepsilon)$, essentially deamortizing the amortized lower bound. We also give a load-oblivious greedy scheme with optimal expected probe count $Θ(1/\varepsilon)$ whose $i$-th probe is at distance $O(i^2)$ from the first probe. Its analysis gives a general variance bound for occupied-cell densities in symmetric probing schemes, implying an $O(\log n/\varepsilon^2)$ expected probe bound for every fixed-shift probing sequence and every load $1-\varepsilon$.
Problem

Research questions and friction points this paper is trying to address.

locality
open addressing
hash tables
probe count
load factor
Innovation

Methods, ideas, or system contributions that make the work stand out.

locality
open addressing
probe complexity
hash tables
lower bounds
🔎 Similar Papers