Popis: |
Computation of the single-source shortest path (SSSP) is a fundamental primitive in many network analytics tasks. With the increasing size of networks to be analysed, there is a need for efficient tools to compute shortest paths, especially on the widely adopted shared-memory multicore architectures. The Δ-stepping algorithm, that trades-off the work efficiency of Dijkstra’s algorithm with the parallelism offered by the Bellman-Ford algorithm, has been found to be among the fastest implementations on various parallel architectures. Despite its widespread popularity, the different design choices in implementing the parallel Δ-stepping algorithm are not properly understood and these design choices can have a significant impact on the final performance. In this paper, we carefully compare two different implementations of the Δ-stepping algorithm for shared-memory multicore architectures: (i) a static workload assignment where the nodes are assigned to threads at the beginning of the algorithm and only the assigned thread can relax edges leading to a node and (ii) a dynamic workload assignment where the nodes are dynamically allocated to threads at the time of bucket relaxation. Based on an extensive empirical study on a range of graph classes, edge density and weight distributions, we show that while the more intuitive and widely used approach of dynamically balanced workload suits dense power-law graphs well, the static partitioning approach outperforms this more intuitive approach on a wide range of graph classes. Our findings can guide a network analyst in selecting the best parallel implementation of the Δ-stepping algorithm for a given analytics task and a given graph class. |