Mark–Scavenge: Waiting for Trash to Take Itself Out
summary
Implements MS-ZGC on OpenJDK that delays evacuation and only scavenges previously selected sparse pages, using just-in-time evacuations to avoid OOM. Compares MS-ZGC to ZGC with microbenchmarks and SpecJBB: reports up to 91% reduction in relocation of dead objects, ~50% less wasted relocation overall, latency improvements of 2–4% and throughput gains of 2–8%, and 20% tail-latency improvement for Cassandra under heavy load.
AI-written summary · about
chapters (14)
- 0:00Mark–Scavenge intro
- 1:45Memory reclamation challenges
- 4:15Wasted work in evacuate
- 7:04Designing Mark–Scavenge
- 9:15Mark–Scavenge cycle
- 11:09Just-in-time evacuation
- 12:31Reducing wasted work
- 13:34Performance under load
- 14:38Key takeaways
- 15:55Q&A
- 16:17Tail latency improvements
- 17:16Cache locality effects
- 18:26Peak memory heuristics
- 19:37Mutator contention
related talks
39mZGC: The Next Generation Low-Latency Garbage Collector
46mZGC: A Scalable Low-Latency Garbage Collector
39mZGC - Paving the GC On-Ramp
48mZGC: A Decade of Redefining Java Performance
49mConcurrent Garbage Collectors: ZGC & Shenandoah
19mZ Garbage Collector: The Next Generation
52mGarbage collection for the humans
25mGarbage Collection Primer
