Home » Java » Core Java » Draft JEP to Remove Deprecated CMS Garbage Collector

About Dustin Marx

Dustin Marx

Draft JEP to Remove Deprecated CMS Garbage Collector

In the 10 April 2017 post “Java Garbage Collectors: When Will G1GC Force CMS Out?,” I discussed JEP 291 (“Deprecate the Concurrent Mark Sweep (CMS) Garbage Collector”) and provided a summary of some of the feedback for and against deprecating (and ultimately removing) the Concurrent Mark Sweep (CMS) Garbage Collector (GC). Earlier this month, a draft JEP called “Remove the Concurrent Mark Sweep Garbage Collector” was created.

The “Summary” section of this draft JEP states, “Remove the Concurrent Mark Sweep (CMS) garbage collector from the set of usable garbage collection algorithms.” Although the “draft” status of this JEP means it’s not targeted to any specific release, the “Non-Goals” section reassures us that the draft JEP is not intended to remove CMS from any releases prior to the release in which CMS is removed. The post “RFC: JEP: Remove the Concurrent Mark Sweep Garbage Collector” states that the current plan is to target CMS removal for JDK 14.

The draft JEP states in the “Risks and Assumptions” section that this draft to remove CMS GC “might be withdrawn” if another “interested credible contributor in the community will step up for maintenance.” However, in the 2+ years since JEP 291 deprecated CMS, no such “interested credible contributor” has offered to maintain CMS. Thomas Schatzl’s post related to this JEP describes this better:


There has also always been the option to organize maintenance of CMS in the community, but nobody even stepped up starting to fix the long-standing existing known minor issues CMS (to get contributors to know CMS code and to give us confidence that these persons can take over maintenance of such a large component).

The draft JEP for removing CMS specifically mentions three recommend alternative garbage collectors: the now-default garbage-first (G1), Oracle-provided ZGC, and Red Hat-provided Shenandoah.

There were multiple objections to deprecating CMS when JEP 291 was under review and there are objections now to the idea of removing CMS altogether. Kirk Pepperdine has written that he and others have observed that “CMS overheads are no where near the level of those seen with G1” and they are “now recommending that customers consider Parallel GC as it offers a far better experience than G1.”

It looks likely that CMS will be removed as a garbage collection option in a forthcoming JDK release (perhaps even as early as JDK 14). As Kirk Pepperdine expressed in another post on the subject, “At the end of the day, if we want CMS we’re going to have to step up and do something about it.” So far, it doesn’t look like anyone’s wanted CMS badly enough to do something about it (which might include working with their preferred JDK provider to have it supported in that provider’s JDK).

Published on Java Code Geeks with permission by Dustin Marx, partner at our JCG program. See the original article here: Draft JEP to Remove Deprecated CMS Garbage Collector

Opinions expressed by Java Code Geeks contributors are their own.

(0 rating, 0 votes)
You need to be a registered member to rate this.
Start the discussion Views Tweet it!
Do you want to know how to develop your skillset to become a Java Rockstar?
Subscribe to our newsletter to start Rocking right now!
To get you started we give you our best selling eBooks for FREE!
1. JPA Mini Book
2. JVM Troubleshooting Guide
3. JUnit Tutorial for Unit Testing
4. Java Annotations Tutorial
5. Java Interview Questions
6. Spring Interview Questions
7. Android UI Design
and many more ....
I agree to the Terms and Privacy Policy

Leave a Reply

avatar

This site uses Akismet to reduce spam. Learn how your comment data is processed.

  Subscribe  
Notify of