skip to main content
10.1145/2814270.2814298acmconferencesArticle/Chapter ViewAbstractPublication PagessplashConference Proceedingsconference-collections
research-article

Automatic memory reclamation for lock-free data structures

Published:23 October 2015Publication History

ABSTRACT

Lock-free data-structures are widely employed in practice, yet designing lock-free memory reclamation for them is notoriously difficult. In particular, all known lock-free reclamation schemes are ``manual'' in the sense that the developer has to specify when nodes have retired and may be reclaimed. Retiring nodes adequately is non-trivial and often requires the modification of the original lock-free algorithm. In this paper we present an automatic lock-free reclamation scheme for lock-free data-structures in the spirit of a mark-sweep garbage collection. The proposed algorithm works with any normalized lock-free algorithm and with no need for the programmer to retire nodes or make changes to the algorithm. Evaluation of the proposed scheme on a linked-list and a hash table shows that it performs similarly to the best manual (lock-free) memory reclamation scheme.

References

  1. D. Alistarh, P. Eugster, M. Herlihy, A. Matveev, and N. Shavit. Stacktrack: An automated transactional approach to concurrent memory reclamation. In EuroSys. ACM, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. J. Auerbach, D. F. Bacon, P. Cheng, D. Grove, B. Biron, C. Gracie, B. McCloskey, A. Micic, and R. Sciampacone. Tax-and-spend: Democratic scheduling for real-time garbage collection. In EMSOFT, pages 245–254, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. A. Braginsky, A. Kogan, and E. Petrank. Drop the anchor: lightweight memory management for non-blocking data structures. In SPAA, pages 33–42. ACM, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. N. Cohen and E. Petrank. Efficient memory management for lock-free data structures with optimistic access. In SPAA. ACM, 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. D. L. Detlefs, P. A. Martin, M. Moir, and G. L. Steele Jr. Lockfree reference counting. DISC, pages 255–271, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. T. L. Harris. A pragmatic implementation of non-blocking linked-lists. In DISC, pages 300–314. Springer, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. T. E. Hart, P. E. McKenney, A. D. Brown, and J. Walpole. Performance of memory reclamation for lockless synchronization. JPDC, pages 1270–1285, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. M. Herlihy. Wait-free synchronization. TOPLAS, 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. M. Herlihy and N. Shavit. The Art of Multiprocessor Programming, Revised Reprint. Elsevier, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. M. Herlihy, V. Luchangco, P. Martin, and M. Moir. Nonblocking memory management support for dynamic-sized data structures. TOCS, 23(2):146–196, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. M. P. Herlihy and J. E. B. Moss. Lock-free garbage collection for multiprocessors. TPDS, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. R. L. Hudson and J. E. B. Moss. Sapphire: Copying GC without stopping the world. In Joint ACM-ISCOPE Conference on Java Grande, pages 48–57, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. A. Kogan and E. Petrank. Wait-free queues with multiple enqueuers and dequeuers. In PPoPP, pages 223–234. ACM, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. A. Kogan and E. Petrank. A methodology for creating fast wait-free data structures. In PPoPP, pages 141–150. ACM, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. M. M. Michael. High performance dynamic lock-free hash tables and list-based sets. In SPAA, pages 73–82. ACM, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. M. M. Michael. Hazard pointers: Safe memory reclamation for lock-free objects. TPDS, 15(6):491–504, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. M. M. Michael and M. L. Scott. Correction of a memory management method for lock-free data structures. Technical report, DTIC Document, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. S. Owens, S. Sarkar, and P. Sewell. A better x86 memory model: x86-tso. In Theorem Proving in Higher Order Logics, pages 391–407. Springer, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. E. Petrank. Can parallel data structures rely on automatic memory managers? In MSPC, pages 1–1. ACM, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. F. Pizlo, D. Frampton, E. Petrank, and B. Steensgard. Stopless: A real-time garbage collector for multiprocessors. In ISMM, pages 159–172, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. F. Pizlo, E. Petrank, and B. Steensgaard. A study of concurrent real-time garbage collectors. In PLDI, pages 33–44, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. F. Pizlo, L. Ziarek, P. Maj, A. L. Hosking, E. Blanton, and J. Vitek. Schism: Fragmentation-tolerant real-time garbage collection. In PLDI, pages 146–159, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. H. Sundell. Wait-free reference counting and memory management. In IPDPS, pages 24b–24b. IEEE, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. S. Timnat and E. Petrank. A practical wait-free simulation for lock-free data structures. In PPoPP, pages 357–368. ACM, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. J. D. Valois. Lock-free linked lists using compare-and-swap. In PODC, pages 214–222. ACM, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Automatic memory reclamation for lock-free data structures

            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
            • Published in

              cover image ACM Conferences
              OOPSLA 2015: Proceedings of the 2015 ACM SIGPLAN International Conference on Object-Oriented Programming, Systems, Languages, and Applications
              October 2015
              953 pages
              ISBN:9781450336895
              DOI:10.1145/2814270
              • cover image ACM SIGPLAN Notices
                ACM SIGPLAN Notices  Volume 50, Issue 10
                OOPSLA '15
                October 2015
                953 pages
                ISSN:0362-1340
                EISSN:1558-1160
                DOI:10.1145/2858965
                • Editor:
                • Andy Gill
                Issue’s Table of Contents

              Copyright © 2015 ACM

              Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

              Publisher

              Association for Computing Machinery

              New York, NY, United States

              Publication History

              • Published: 23 October 2015

              Permissions

              Request permissions about this article.

              Request Permissions

              Check for updates

              Qualifiers

              • research-article

              Acceptance Rates

              Overall Acceptance Rate268of1,244submissions,22%

              Upcoming Conference

            PDF Format

            View or Download as a PDF file.

            PDF

            eReader

            View online with eReader.

            eReader