Linear probing is one of the simplest and most space-efficient approaches to hash table design, and is widely used in sequential settings due to its compact memory layout. However, designing a concurrent linear-probing hash table with strong liveness guarantees has proved difficult, and only a handful of such algorithms have been proposed, all of which either restrict concurrency or rely on large per-entry metadata, thereby compromising space efficiency. We present a lock-free linear-probing hash table with wait-free lookups that retains the core advantages of sequential linear probing while handling contention gracefully. Our design uses only a small amount of metadata per table entry: a constant number of additional bits when using LL/SC, or a logarithmic number of bits when using CAS. The algorithm is linearizable and lock-free, supports insert, delete, and wait-free lookup operations, and is able to safely reclaim space used by deleted elements without rebuilding the table. We analyze the amortized step complexity of our hash table assuming no concurrent insertions of the same key, and show that each operation has expected amortized step complexity matching that of sequential linear probing, up to the point contention per key.


翻译:线性探测是哈希表设计中最简单且空间效率最高的方法之一,因其紧凑的内存布局而广泛应用于串行场景。然而,设计具有强活性保证的并发线性探测哈希表一直颇具挑战,目前仅有少量此类算法被提出,它们要么限制并发性,要么依赖每个条目的大量元数据,从而牺牲了空间效率。我们提出了一种免锁线性探测哈希表,支持无等待查找操作,既保留了串行线性探测的核心优势,又能优雅地处理竞争。该设计每个表条目仅需少量元数据:使用LL/SC时需常数比特位,使用CAS时仅需对数级比特位。该算法可线性化且无锁,支持插入、删除及无等待查找操作,并能在不重建哈希表的情况下安全回收已删除元素所占用的空间。我们分析了假设无同一键并发插入情况下哈希表的均摊步骤复杂度,并证明在键级竞争限制下,每次操作的预期均摊步骤复杂度与串行线性探测相匹配。

0
下载
关闭预览

相关内容

专知会员服务
19+阅读 · 2021年5月16日
专知会员服务
47+阅读 · 2020年11月13日
专知会员服务
50+阅读 · 2020年6月14日
Github项目推荐 | DeepHash - 深度学习哈希开源库
AI研习社
27+阅读 · 2019年4月30日
那些值得推荐和收藏的线性代数学习资源
最新|深度离散哈希算法,可用于图像检索!
全球人工智能
14+阅读 · 2017年12月15日
国家自然科学基金
0+阅读 · 2017年12月31日
国家自然科学基金
0+阅读 · 2017年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
VIP会员
最新内容
战力倍增器:自主武器系统与乌克兰及加沙冲突
人工智能赋能战场情报:提速决策进程
专知会员服务
2+阅读 · 7月17日
《拥抱新兴技术:面向未来军官的教育革新》
专知会员服务
5+阅读 · 7月17日
《无人地面战车(UGV)的崛起》报告
专知会员服务
7+阅读 · 7月16日
美陆军任务式指挥人工智能解决方案
专知会员服务
13+阅读 · 7月16日
相关基金
国家自然科学基金
0+阅读 · 2017年12月31日
国家自然科学基金
0+阅读 · 2017年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员