arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2104.15003cs.DCcs.DS
收藏

并发有界队列的内存界限

Memory Bounds for Concurrent Bounded Queues

Vitaly Aksenov, Nikita Koval, Petr Kuznetsov, Anton Paramonov

AI总结:

本文研究无阻塞有界队列的内存最优性,证明在一般情形下其内存开销与并发进程数成线性关系,为并发数据结构内存优化提供理论界限。

摘要:

并发数据结构除了存储元素所需的内存外,通常还需要额外的内存来处理同步问题。根据这些额外内存的数量,不同实现的内存友好程度可能更高或更低。内存最优的实现享有最小可能的内存开销,这在实践中能够减少缓存未命中和不必要的内存回收。在本文中,我们讨论无阻塞有界队列的内存最优性。本质上,我们研究了构造这样一种实现的可能性:它利用预先分配的数组来存储元素,并且只使用常量内存开销,例如用于 enqueue(..) 和 dequeue() 操作的两个定位计数器。当 ABA 问题被排除时,例如假设硬件支持 LL/SC 指令或者所有插入的元素都互不相同,这样的实现可以很容易地构造出来。然而,在一般情形下,我们证明内存最优的无阻塞有界队列会产生与并发进程数量成线性关系的开销。这些结果不仅为并发算法开发者提供了有用的直觉,也为并发数据结构中内存最优性现象开辟了新的研究方向。

英文摘要:

Concurrent data structures often require additional memory for handling synchronization issues in addition to memory for storing elements. Depending on the amount of this additional memory, implementations can be more or less memory-friendly. A memory-optimal implementation enjoys the minimal possible memory overhead, which, in practice, reduces cache misses and unnecessary memory reclamation. In this paper, we discuss the memory-optimality of non-blocking bounded queues. Essentially, we investigate the possibility of constructing an implementation that utilizes a pre-allocated array to store elements and constant memory overhead, e.g., two positioning counters for enqueue(..) and dequeue() operations. Such an implementation can be readily constructed when the ABA problem is precluded, e.g., assuming that the hardware supports LL/SC instructions or all inserted elements are distinct. However, in the general case, we show that a memory-optimal non-blocking bounded queue incurs linear overhead in the number of concurrent processes. These results not only provide helpful intuition for concurrent algorithm developers but also open a new research avenue on the memory-optimality phenomenon in concurrent data structures.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑