skip to main content
research-article
Public Access

The SprayList: a scalable relaxed priority queue

Published:24 January 2015Publication History
Skip Abstract Section

Abstract

High-performance concurrent priority queues are essential for applications such as task scheduling and discrete event simulation. Unfortunately, even the best performing implementations do not scale past a number of threads in the single digits. This is because of the sequential bottleneck in accessing the elements at the head of the queue in order to perform a DeleteMin operation. In this paper, we present the SprayList, a scalable priority queue with relaxed ordering semantics. Starting from a non-blocking SkipList, the main innovation behind our design is that the DeleteMin operations avoid a sequential bottleneck by ``spraying'' themselves onto the head of the SkipList list in a coordinated fashion. The spraying is implemented using a carefully designed random walk, so that DeleteMin returns an element among the first O(p log^3 p) in the list, with high probability, where p is the number of threads. We prove that the running time of a DeleteMin operation is O(log^3 p), with high probability, independent of the size of the list. Our experiments show that the relaxed semantics allow the data structure to scale for high thread counts, comparable to a classic unordered SkipList. Furthermore, we observe that, for reasonably parallel workloads, the scalability benefits of relaxation considerably outweigh the additional work due to out-of-order execution.

References

  1. Stanford large network dataset collection. http://snap.stanford. edu/data/index.html. Accessed: Sept. 2014.Google ScholarGoogle Scholar
  2. Y. Afek, M. Hakimi, and A. Morrison. Fast and scalable rendezvousing. Distributed Computing, 26(4):243–269, 2013.Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. D. Alistarh, J. Aspnes, S. Gilbert, and R. Guerraoui. The complexity of renaming. In 52nd Annual IEEE Symposium on Foundations of Computer Science (FOCS), pages 718–727, Oct. 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. D. Alistarh, J. Kopinsky, J. Li, and N. Shavit. Spraylist. https: //github.com/jkopinsky/SprayList.Google ScholarGoogle Scholar
  5. D. Alistarh, J. Kopinsky, J. Li, and N. Shavit. The spraylist: A scalable relaxed priority queue. Technical Report MSR-TR-2014-16, December 2014.Google ScholarGoogle Scholar
  6. D. Basin, R. Fan, I. Keidar, O. Kiselov, and D. Perelman. Cafe: Scalable task pools with adjustable fairness and contention. In Proceedings of the 25th International Conference on Distributed Computing, DISC’11, pages 475–488, Berlin, Heidelberg, 2011. Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. A. Braginsky and E. Petrank. A lock-free b+tree. In 24th ACM Symposium on Parallelism in Algorithms and Architectures, SPAA ’12, Pittsburgh, PA, USA, pages 58–67, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. G. S. Brodal, J. L. Träff, and C. D. Zaroliagis. A parallel priority queue with constant time operations. J. Parallel Distrib. Comput., 49(1):4– 21, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. I. Calciu, H. Mendes, and M. Herlihy. The Adaptive Priority Queue with Elimination and Combining. ArXiv e-prints, Aug. 2014.Google ScholarGoogle Scholar
  10. T. Crain, V. Gramoli, and M. Raynal. A speculation-friendly binary search tree. ACM SIGPLAN Notices, 47(8):161–170, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. N. Deo and S. Prasad. Parallel heap: An optimal parallel priority queue. The Journal of Supercomputing, 6(1):87–98, Mar. 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. D. Dice, Y. Lev, and M. Moir. Scalable statistics counters. In 25th ACM Symposium on Parallelism in Algorithms and Architectures, SPAA ’13, Montreal, QC, Canada, pages 43–52, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. B. Drawert, S. Engblom, and A. Hellander. Urdme: a modular framework for stochastic simulation of reaction-transport processes in complex geometries. BMC Systems Biology, 6(76), 2012.Google ScholarGoogle Scholar
  14. F. Ellen, D. Hendler, and N. Shavit. On the inherent sequentiality of concurrent objects. SIAM J. Comput., 41(3):519–536, 2012.Google ScholarGoogle Scholar
  15. K. Fraser. Practical lock-freedom. PhD thesis, PhD thesis, Cambridge University Computer Laboratory, 2003. Also available as Technical Report UCAM-CL-TR-579, 2004.Google ScholarGoogle Scholar
  16. T. A. Henzinger, C. M. Kirsch, H. Payer, A. Sezgin, and A. Sokolova. Quantitative relaxation of concurrent data structures. In Proceedings of the 40th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL ’13, pages 317–328, New York, NY, USA, 2013. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. M. Herlihy and N. Shavit. The art of multiprocessor programming. Morgan Kaufmann, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. M. Herlihy, N. Shavit, and M. Tzafrir. Hopscotch hashing. In Proceedings of the 22nd International Symposium on Distributed Computing, DISC 2008, Arcachon, France, pages 350–364, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. R. M. Karp and Y. Zhang. Parallel algorithms for backtrack search and branch-and-bound. J. ACM, 40(3):765–789, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. C. E. Leiserson, R. L. Rivest, C. Stein, and T. H. Cormen. Introduction to algorithms. The MIT press, 2001.Google ScholarGoogle Scholar
  21. J. Lindén and B. Jonsson. A skiplist-based concurrent priority queue with minimal memory contention. In Principles of Distributed Systems, pages 206–220. Springer, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. I. Lotan and N. Shavit. Skiplist-based concurrent priority queues. In Parallel and Distributed Processing Symposium, 2000. IPDPS 2000. Proceedings. 14th International, pages 263–268. IEEE, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. D. Nguyen, A. Lenharth, and K. Pingali. A lightweight infrastructure for graph analytics. In Proceedings of the Twenty-Fourth ACM Symposium on Operating Systems Principles, SOSP ’13, pages 456–471, New York, NY, USA, 2013. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. W. Pugh. Skip lists: a probabilistic alternative to balanced trees. Communications of the ACM, 33(6):668–676, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. W. Pugh. Concurrent maintenance of skip lists. 1998.Google ScholarGoogle Scholar
  26. P. Sanders. Randomized priority queues for fast parallel access. Journal Parallel and Distributed Computing, Special Issue on Parallel and Distributed Data Structures, 49:86–97, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. N. Shavit. Data structures in the multicore age. Commun. ACM, 54(3):76–84, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. H. Sundell and P. Tsigas. Fast and lock-free concurrent priority queues for multi-thread systems. Journal of Parallel and Distributed Computing, 65(5):609–627, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. M. Wimmer, D. Cederman, F. Versaci, J. L. Träff, and P. Tsigas. Data structures for task-based priority scheduling. In Proceedings of the 19th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP 2014), 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. M. Wimmer, G. J., J. L. Träff, and P. Tsigas. The lock-free k-lsm relaxed priority queue. In Proceedings of the 20th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP 2015), 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. The SprayList: a scalable relaxed priority queue

            Recommendations

            Comments

            Login options

            Check if you have access through your login credentials or your institution to get full access on this article.

            Sign in

            Full Access

            • Published in

              cover image ACM SIGPLAN Notices
              ACM SIGPLAN Notices  Volume 50, Issue 8
              PPoPP '15
              August 2015
              290 pages
              ISSN:0362-1340
              EISSN:1558-1160
              DOI:10.1145/2858788
              • Editor:
              • Andy Gill
              Issue’s Table of Contents
              • cover image ACM Conferences
                PPoPP 2015: Proceedings of the 20th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming
                January 2015
                290 pages
                ISBN:9781450332057
                DOI:10.1145/2688500

              Copyright © 2015 ACM

              Publisher

              Association for Computing Machinery

              New York, NY, United States

              Publication History

              • Published: 24 January 2015

              Check for updates

              Qualifiers

              • research-article

            PDF Format

            View or Download as a PDF file.

            PDF

            eReader

            View online with eReader.

            eReader
            About Cookies On This Site

            We use cookies to ensure that we give you the best experience on our website.

            Learn more

            Got it!