Abstract
Implementing counting networks on shared-memory multiprocessor machines often incurs a performance penalty proportional to the depth of the networks and the extent to which concurrent processors access the same memory location at the same time. In this work, we examine the dependence of performance on the width of the balancers used in constructing such networks.
Our main result is a construction of counting networks (and, hence, sorting networks) with perfect power width p k, for any integers p≥2 and k≥1. This construction is built on balancers of width p, and generalizes in a novel way the periodic counting network of Aspnes, Herlihy and Shavit [3], built on balancers of width 2. This result provides a partial answer to a question of Aharonson and Attiya [1].
The depth of these networks is k 2, thus implying decrease in depth of counting networks through an increase in balancer width. Furthermore, we provide a formal analysis of the performance of our construction as measured by contention [8]. Through a novel use of recurrence relations, we show that our counting networks incur a contention of Θ(nk 2/p k−1) in the presence of n concurrent processors. This bound implies a trade-off between depth and contention.
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
E. Aharonson and H. Attiya, “Counting Networks with Arbitrary Fan-Out,” in Proceedings of the 3rd ACM-SIAM Symposium on Discrete Algorithms, pp. 104–113, January 1992.
M. Ajtai, J. Komlos and E. Szemeredi, “Halvers and Expanders,” in Proceedings of the 33rd Annual IEEE Symposium on Foundations of Computer Science, pp. 686–692, October 1992.
J. Aspnes, M. Herlihy and N. Shavit, “Counting Networks and Multi-Processor Coordination,” in Proceedings of the 23rd Annual ACM Symposium on Theory of Computing, pp. 348–358, May 1991. Expanded version: “Counting Networks,” Technical Memo MIT/LCS/TM-451, Laboratory of Computer Science, MIT, June 1991.
K. E. Batcher, “Sorting Networks and their Applications,” in Proceedings of AFIPS Joint Computer Conference, 32, pp. 338–334, 1968.
R. Becker, D. Nassimi and Y. Perl, “The New Class of g-Chain Periodic Sorters,” in Proceedings of the 5th Annual ACM Symposium on Parallel Algorithms and Architectures, July 1993.
T. Cormen, C. Leiserson and R. Rivest, Introduction to Algorithms, Mc-Graw Hill and MIT Press, 1990.
M. Dowd, Y. Perl, L. Rudolph and M. Saks, “The Periodic Balanced Sorting Network,” Journal of the ACM, Vol. 36, No. 4, pp. 738–757, October 1989.
C. Dwork, M. Herlihy and O. Waarts, “Contention in Shared Memory Algorithms,” in Proceedings of the 25th Annual ACM Symposium on Theory of Computing, May 1993.
A. Gerbessiotis, “Sorting and Counting Networks,” unpublished manuscript, Harvard University, October 1992.
M. Herlihy, B.-C. Lim and N. Shavit, “Low Contention Load Balancing on Large-Scale Multiprocessors,” in Proceedings of the 4th Annual ACM Symposium on Parallel Algorithms and Architectures, July 1992.
M. Herlihy, N. Shavit and O. Waarts, “Low Contention Linearizablc Counting Networks,” in Proceedings of the 32nd Annual IEEE Symposium on Foundations of Computer Science, pp. 526–535, October 1991.
M. Klugerman and C. Plaxton, “Small-Depth Counting Networks,” in Proceedings of the 24th Annual ACM Symposium on Theory of Computing, pp. 417–428, May 1992.
D. Knuth, Sorting and Searching, Volume 3 of The Art of Computer Programming, Addison-Wesley, 1973.
S. S. Tseng and R. C. Lee, “A new Parallel Sorting Algorithm Based upon Min-Mid-Max Operations,” BIT, Vol. 24, pp. 187–195, 1984.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1993 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Hardavellas, N., Karakos, D., Mavronicolas, M. (1993). Notes on sorting and counting networks (extended abstract). In: Schiper, A. (eds) Distributed Algorithms. WDAG 1993. Lecture Notes in Computer Science, vol 725. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-57271-6_39
Download citation
DOI: https://doi.org/10.1007/3-540-57271-6_39
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-57271-8
Online ISBN: 978-3-540-48029-7
eBook Packages: Springer Book Archive