arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2304.09331cs.DScs.DC
收藏

可证明高效且内部确定性的并行并查集(Union-Find)

Provably-Efficient and Internally-Deterministic Parallel Union-Find

Alexander Fedorov, Diba Hashemi, Giorgi Nadiradze, Dan Alistarh

AI总结:

本文分析 Union-Find 的内在并行性,证明随机边序下争用期望界,并提出内部确定、工作高效且可扩展的并行算法,辅以接近最优的下界和实验验证。

摘要:

确定经典顺序算法中内在并行性的程度,并利用它实现快速并行执行,是并行计算中的一个关键主题,而且人们已经对大量经典算法进行了详细分析。在本文中,我们针对基础性的并查集(Union-Find)问题首次开展此类分析;在该问题中,给定一个以边序列形式表示的图,并且必须在边加入过程中维护其连通性结构。我们证明,在合理假设下,该问题的经典顺序算法具有良好的可并行性,从而回应了 [Blelloch, 2017] 提出的猜想。更具体地说,我们通过一种新的势函数论证表明:在均匀随机边排序下,并查集的并行操作不太可能相互干扰:并行处理该图的 T 个并发线程预期遇到内存争用的次数为 O(T^2·log |V|·log |E|),其中 |E| 和 |V| 分别是图中的边数和节点数。我们利用这一结果设计了一种新的并行 Union-Find 算法,该算法既具有内部确定性,即保证其结果与顺序执行的结果相匹配,同时又是工作高效且可扩展的,前提是线程数 T 为 O(|E|^{1/3−ε}),其中 ε>0 为任意小常数;这一条件对大多数大型真实世界图都成立。我们给出了若干下界,表明我们的分析接近最优;实验结果也表明,内部确定性带来的性能代价有限。

英文摘要:

Determining the degree of inherent parallelism in classical sequential algorithms and leveraging it for fast parallel execution is a key topic in parallel computing, and detailed analyses are known for a wide range of classical algorithms. In this paper, we perform the first such analysis for the fundamental Union-Find problem, in which we are given a graph as a sequence of edges, and must maintain its connectivity structure under edge additions. We prove that classic sequential algorithms for this problem are well-parallelizable under reasonable assumptions, addressing a conjecture by [Blelloch, 2017]. More precisely, we show via a new potential argument that, under uniform random edge ordering, parallel union-find operations are unlikely to interfere: $T$ concurrent threads processing the graph in parallel will encounter memory contention $O(T^2 \cdot \log |V| \cdot \log |E|)$ times in expectation, where $|E|$ and $|V|$ are the number of edges and nodes in the graph, respectively. We leverage this result to design a new parallel Union-Find algorithm that is both internally deterministic, i.e., its results are guaranteed to match those of a sequential execution, but also work-efficient and scalable, as long as the number of threads $T$ is $O(|E|^{\frac{1}{3} - \varepsilon})$, for an arbitrarily small constant $\varepsilon > 0$, which holds for most large real-world graphs. We present lower bounds which show that our analysis is close to optimal, and experimental results suggesting that the performance cost of internal determinism is limited.

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

↑