Advertisement

ParMarkSplit: A Parallel Mark-Split Garbage Collector Based on a Lock-Free Skip-List

  • Nhan Nguyen
  • Philippas Tsigas
  • Håkan Sundell
Part of the Lecture Notes in Computer Science book series (LNCS, volume 8878)

Abstract

Mark-split is a garbage collection algorithm that combines advantages of both the mark-sweep and the copying collection algorithms. In this paper, we present a parallel mark-split garbage collector (GC). Our parallel design introduces and makes use of an efficient concurrency control mechanism for handling the list of free memory intervals. This mechanism is based on a lock-free skip-list design which supports an extended set of operations. Beside basic operations, it can perform a composite one that can search and remove and also insert two elements atomically. We have implemented the parallel mark-split GC in OpenJDK’s HotSpot virtual machine. We experimentally evaluate our collector and compare it with the default concurrent mark-sweep GC in HotSpot, using the DaCapo benchmarks, on two contemporary multiprocessor systems; one has 12 Intel Nehalem cores with HyperThreading and the other has 48 AMD Bulldozer cores. The evaluation shows that our parallel mark-split keeps the characteristics of the sequential mark-split, that it performs better than the concurrent mark-sweep in applications that have low live/garbage ratio, and have live objects locating contiguously, therefore being marked consecutively. Our parallel mark-split performs significantly better than a trivial parallelization based on locks in terms of both collection time and scalability.

Keywords

garbage collector concurrent programming mark-split mark-sweep parallel garbage collection lock-free data structures 

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    McCarthy, J.: Recursive functions of symbolic expressions and their computation by machine, part i. Commun. ACM 3, 184–195 (1960)CrossRefzbMATHGoogle Scholar
  2. 2.
    Cheney, C.J.: A nonrecursive list compacting algorithm. Commun. ACM 13, 677–678 (1970)CrossRefzbMATHGoogle Scholar
  3. 3.
    Hughes, R.J.M.: A semi-incremental garbage collection algorithm. Software: Practice and Experience 12(11), 1081–1082 (1982)Google Scholar
  4. 4.
    Blackburn, S.M., McKinley, K.S.: Immix: A mark-region garbage collector with space efficiency, fast collection, and mutator performance. SIGPLAN Not. 43(6), 22–32 (2008)CrossRefGoogle Scholar
  5. 5.
    Detlefs, D., Flood, C., Heller, S., Printezis, T.: Garbage-first garbage collection. In: Proceedings of the 4th ISMM, pp. 37–48. ACM (2004)Google Scholar
  6. 6.
    Sagonas, K., Wilhelmsson, J.: Mark and split. In: Proceedings of the 5th International Symposium on Memory Management, ISMM 2006, pp. 29–39. ACM (2006)Google Scholar
  7. 7.
    Herlihy, M., Shavit, N.: The Art of Multiprocessor Programming. Morgan Kaufmann (2008)Google Scholar
  8. 8.
    Sundell, H., Tsigas, P.: Fast and lock-free concurrent priority queues for multi-thread systems. J. Parallel Distrib. Comput. 65(5), 609–627 (2005)CrossRefzbMATHGoogle Scholar
  9. 9.
    Michael, M.M.: Hazard pointers: Safe memory reclamation for lock-free objects. IEEE Transactions on Parallel and Distributed Systems 15(8) (August 2004)Google Scholar
  10. 10.
    Sundell, H., Gidenstam, A., Papatriantafilou, M., Tsigas, P.: A Lock-Free Algorithm for Concurrent Bags. In: Proceedings of the 23rd ACM SPAA. ACM (2011)Google Scholar
  11. 11.
    Printezis, T., Detlefs, D.: A generational mostly-concurrent garbage collector. SIGPLAN Not. 36, 143–154 (2000)CrossRefGoogle Scholar
  12. 12.
    Blackburn, S.M., et al.: The dacapo benchmarks: Java benchmarking development and analysis. SIGPLAN Not. 41, 169–190 (2006)CrossRefGoogle Scholar
  13. 13.
    Gidra, L., Thomas, G., Sopena, J., Shapiro, M.: Assessing the scalability of garbage collectors on many cores. In: Proceedings of the 6th PLOS Workshop. ACM (2011)Google Scholar
  14. 14.
    Kalibera, T., et al.: A black-box approach to understanding concurrency in dacapo. In: The UK MM-NET Workshop on Memory Management (April 2012)Google Scholar
  15. 15.
    Persson, M., Cummins, H.: Java technology, ibm style: Garbage collection policies. IBM DeveloperWorks (May 2006)Google Scholar

Copyright information

© Springer International Publishing Switzerland 2014

Authors and Affiliations

  • Nhan Nguyen
    • 1
  • Philippas Tsigas
    • 1
  • Håkan Sundell
    • 2
  1. 1.Chalmers University of TechnologyGothenburgSweden
  2. 2.University of BoråsBoråsSweden

Personalised recommendations