ABSTRACT
Garbage collection (GC) pauses are a notorious issue threatening the latency of applications. To mitigate this problem, state-of-the-art concurrent copying collectors allow GC threads to run simultaneously with application threads (mutators) in nearly all GC phases. However, the design of concurrent copying collectors does not always lead to low application latency. To this end, this work studies the behaviors of mainstream concurrent copying collectors in OpenJDK and mainly focuses on long application pauses under heavy workloads. By analyzing the design of those collectors, this work uncovers that lengthy pre-reclamation cycles (including GC phases before actual memory release), high GC frequency, and large metadata maintenance overhead are major factors for long pauses. Therefore, this work proposes Jade, a concurrent copying collector aiming to achieve both short pauses and high GC efficiency. Compared with existing collectors, Jade provides a group-wise collection mechanism to shorten pre-reclamation cycles while controlling GC frequency. It also embraces a generational heap layout and a single-phase algorithm to maximize young GC's throughput. The evaluation results on representative latency-critical applications show that Jade can reach sub-millisecond-level pauses even under heavy workloads and significantly improve applications' peak throughput compared with state-of-the-art concurrent collectors.
- Apache. Welcome to apache hbase. https://hbase.apache.org/, 2022.Google Scholar
- Stephen M. Blackburn, Robin Garner, Chris Hoffmann, Asjad M. Khan, Kathryn S. McKinley, Rotem Bentzur, Amer Diwan, Daniel Feinberg, Daniel Frampton, Samuel Z. Guyer, Martin Hirzel, Antony L. Hosking, Maria Jump, Han Bok Lee, J. Eliot B. Moss, Aashish Phansalkar, Darko Stefanovic, Thomas VanDrunen, Daniel von Dincklage, and Ben Wiedermann. The dacapo benchmarks: java benchmarking development and analysis. In OOPSLA, pages 169--190. ACM, 2006.Google ScholarDigital Library
- Stephen M. Blackburn and Kathryn S. McKinley. Immix: a mark-region garbage collector with space efficiency fast collection, and mutator performance. In PLDI, pages 22--32. ACM, 2008.Google Scholar
- Rodrigo Bruno and Paulo Ferreira. POLM2: automatic profiling for object lifetime-aware memory management for hotspot big data applications. In Middleware, pages 147--160. ACM, 2017.Google Scholar
- Rodrigo Bruno, Luís Picciochi Oliveira, and Paulo Ferreira. NG2C: pretenuring garbage collection with dynamic generations for hotspot big data applications. In ISMM, pages 2--13. ACM, 2017.Google ScholarDigital Library
- Rodrigo Bruno, Duarte Patrício, José Simäo, Luís Veiga, and Paulo Ferreira. Runtime object lifetime profiler for latency sensitive big data applications. In EuroSys, pages 28:1-28:16. ACM, 2019.Google ScholarDigital Library
- Zixian Cai, Stephen M. Blackburn, Michael D. Bond, and Martin Maas. Distilling the real cost of production garbage collectors. In ISPASS, pages 46--57. IEEE, 2022.Google ScholarCross Ref
- Maria Carpen-Amarie, Yaroslav Hayduk, Pascal Felber, Christof Fetzer, Gaël Thomas, and Dave Dice. Towards an efficient pauseless java GC with selective htm-based access barriers. In ManLang, pages 85--91. ACM, 2017.Google ScholarDigital Library
- Jiho Choi, Thomas Shull, and Josep Torrellas. Biased reference counting: minimizing atomic operations in garbage collection. In PACT, pages 35:1-35:12. ACM, 2018.Google ScholarDigital Library
- Cliff Click, Gil Tene, and Michael Wolf. The pauseless GC algorithm. In VEE, pages 46--56. ACM, 2005.Google ScholarDigital Library
- Brian F. Cooper, Adam Silberstein, Erwin Tam, Raghu Ramakrishnan, and Russell Sears. Benchmarking cloud serving systems with YCSB. In SoCC, pages 143--154. ACM, 2010.Google ScholarDigital Library
- Standard Performance Evaluation Corporation. The specjbb2915 benchmark. https://www.spec.org/jbb2015/, 2021.Google Scholar
- David Detlefs, Christine H. Flood, Steve Heller, and Tony Printezis. Garbage-first garbage collection. In ISMM, pages 37--48. ACM, 2004.Google ScholarDigital Library
- L. Peter Deutsch and Daniel G. Bobrow. An efficient, incremental, automatic garbage collector. Commun. ACM, 19(9):522--526, 1976.Google ScholarDigital Library
- Christine H. Flood, Roman Kennke, Andrew E. Dinn, Andrew Haley, and Roland Westrelin. Shenandoah: An open-source concurrent compacting garbage collector for openjdk. In PPPJ, pages 13:1-13:9. ACM, 2016.Google ScholarDigital Library
- Dacapo Group. The dacapo benchmark suite (chopin development). https://github.com/dacapobench/dacapobench/tree/dev-chopin, 2022.Google Scholar
- H2. H2 database engine. https://www.h2database.com/html/main.html, 2022.Google Scholar
- Balaji Iyengar, Gil Tene, Michael Wolf, and Edward F. Gehringer. The collie: await-free compacting collector. In ISMM, pages 85--96. ACM, 2012.Google Scholar
- Stefan Johansson. Gc progress from jdk 8 to jdk 17. https://kstefanj.github.io/2021/11/24/gc-progress-8-17.html, 2021.Google Scholar
- Haim Kermany and Erez Petrank. The compressor: concurrent, incremental, and parallel compaction. In Proceedings of the 27th ACM SIGPLAN Conference on Programming Language Design and Implementation, pages 354--363, 2006.Google ScholarDigital Library
- Chris Lattner and Vikram S. Adve. Transparent pointer compression for linked data structures. In Memory System Performance, pages 24--35. ACM, 2005.Google ScholarDigital Library
- Per Lidén and Stefan Karlsson. The z garbage collector - low latency gc for openjdk. http://cr.openjdk.java.net/ pliden/slides/ZGC-Jfokus-2018.pdf, 2018.Google Scholar
- Haoran Ma, Shi Liu, Chenxi Wang, Yifan Qiao, Michael D. Bond, Stephen M. Blackburn, Miryung Kim, and Guoqing Harry Xu. Mako: a low-pause, high-throughput evacuating collector for memory-disaggregated datacenters. In PLDI, pages 92--107. ACM, 2022.Google ScholarDigital Library
- Khanh Nguyen, Lu Fang, Guoqing Xu, Brian Demsky, Shan Lu, Sanazsadat Alamian, and Onur Mutlu. Yak: A high-performance big-data-friendly garbage collector. In OSDI, pages 349--365. USENIX Association, 2016.Google Scholar
- OpenJDK. Zgc - the z garbage collector. https://openjdk.org/projects/zgc/, 2022.Google Scholar
- Erik Österlund and Welf Löwe. Block-free concurrent GC: stack scanning and copying. In ISMM, pages 1--12. ACM, 2016.Google ScholarDigital Library
- Filip Pizlo, Daniel Frampton, Erez Petrank, and Bjarne Steensgaard. Stopless: a real-time garbage collector for multiprocessors. In ISMM, pages 159--172. ACM, 2007.Google ScholarDigital Library
- Filip Pizlo, Erez Petrank, and Bjarne Steensgaard. A study of concurrent real-time garbage collectors. In PLDI, pages 33--44. ACM, 2008.Google ScholarDigital Library
- Android Open Source Project. Art gc overview. https://source.android.com/docs/core/runtime/gc-debug#art_gc_overview, 2022.Google Scholar
- Thomas Schatzl. Java garbage collection: The 10-release evolution from jdk 8 to jdk 18. https://blogs.oracle.com/javamagazine/post/java-garbage-collectors-evolution, 2022.Google Scholar
- Rifat Shahriyar, Stephen M. Blackburn, and Daniel Frampton. Down for the count? getting reference counting back in the ring. In ISMM, pages 73--84. ACM, 2012.Google ScholarDigital Library
- Rifat Shahriyar, Stephen M. Blackburn, Xi Yang, and Kathryn S. McKinley. Taking off the gloves with reference counting immix. In OOPSLA, pages 93--110. ACM, 2013.Google Scholar
- Gil Tene, Balaji Iyengar, and Michael Wolf. C4: the continuously concurrent compacting collector. In ISMM, pages 79--88. ACM, 2011.Google ScholarDigital Library
- TPC. Tpc-c is an on-line transaction processing benchmark. https://www.tpc.org/tpcc/, 2022.Google Scholar
- David M. Ungar. Generation scavenging: A non-disruptive high performance storage reclamation algorithm. In Software Development Environments (SDE), pages 157--167. ACM, 1984.Google Scholar
- Chenxi Wang, Haoran Ma, Shi Liu, Yifan Qiao, Jonathan Eyolfson, Christian Navasca, Shan Lu, and Guoqing Harry Xu. Memliner: Lining up tracing and application for a far-memory-friendly runtime. In OSDI, pages 35--53. USENIX Association, 2022.Google Scholar
- wenyuzhao. Dacapo minheap values. https://gist.github.com/wenyuzhao/29e3e0e10bb68c4f2862851c874e0275, 2023.Google Scholar
- wenyuzhao. Incorrect heap usage reporting. https://github.com/mmtk/mmtk-openjdk/issues/270, 2024.Google Scholar
- Mingyu Wu, Ziming Zhao, Yanfei Yang, Haoyu Li, Haibo Chen, Binyu Zang, Haibing Guan, Sanhong Li, Chuansheng Lu, and Tongbao Zhang. Platinum: A cpu-efficient concurrent garbage collector for tail-reduction of interactive services. In USENIX Annual Technical Conference, pages 159--172. USENIX Association, 2020.Google Scholar
- Yanfei Yang, Mingyu Wu, Haibo Chen, and Binyu Zang. Bridging the performance gap for copy-based garbage collectors atop non-volatile memory. In EuroSys, pages 343--358. ACM, 2021.Google ScholarDigital Library
- Wenyu Zhao, Stephen M. Blackburn, and Kathryn S. McKinley. Low-latency, high-throughput garbage collection. In PLDI, pages 76--91. ACM, 2022.Google Scholar
Index Terms
- Jade: A High-throughput Concurrent Copying Garbage Collector
Recommendations
A generational on-the-fly garbage collector for Java
PLDI '00: Proceedings of the ACM SIGPLAN 2000 conference on Programming language design and implementationAn on-the-fly garbage collector does not stop the program threads to perform the collection. Instead, the collector executes in a separate thread (or process) in parallel to the program. On-the-fly collectors are useful for multi-threaded applications ...
A parallel, incremental, mostly concurrent garbage collector for servers
Multithreaded applications with multigigabyte heaps running on modern servers provide new challenges for garbage collection (GC). The challenges for “server-oriented” GC include: ensuring short pause times on a multigigabyte heap while minimizing ...
A generational on-the-fly garbage collector for Java
An on-the-fly garbage collector does not stop the program threads to perform the collection. Instead, the collector executes in a separate thread (or process) in parallel to the program. On-the-fly collectors are useful for multi-threaded applications ...
Comments