Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to implement a default garbage collector using jvm

2025-03-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/02 Report--

How to use jvm to implement a default garbage collector, for this problem, this article details the corresponding analysis and solution, hoping to help more small partners who want to solve this problem find a simpler and easier way.

jvm default garbage collector

jdk1.7 Default garbage collector Parallel Scavenge +Parallel Old

jdk1.8 Default garbage collector Parallel Scavenge +Parallel Old

jdk1.9 Default garbage collector G1

-XX:+PrintCommandLineFlagsjvm parameter to view default settings Collector type

-XX:+ PrintGC Details can also be judged by the new generation and old generation names of the printed GC logs

Serial collector:

DefNew: Yes Use-XX:+UseSerialGC (Cenozoic, older generations use serial recycling collectors).

Parallel collectors:

ParNew: Either use-XX:+UseParNewGC (parallel collector for Cenozoic generation, serial collector for older generation) or-XX:+ UseConcepMarkSweepGC (parallel collector for Cenozoic generation, CMS for older generation).

PSYoungGen: Either use-XX:+UseParallelOldGC (parallel collector for new generation, serial collector for old generation) or-XX:+UseParallelGC (parallel collector for new generation, serial collector for old generation)

garbage-first heap: Yes Use-XX:+UseG1GC

About how to use jvm to achieve a default garbage collector problem answer to share here, I hope the above content can have some help for everyone, if you still have a lot of doubts not solved, you can pay attention to the industry information channel to learn more related knowledge.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report