当前位置:网站首页>JVM简述 GC垃圾回收机制
JVM简述 GC垃圾回收机制
2022-07-15 23:18:00 【孙慧德】

JVM堆内存大小的调整
如何修改堆内存大小?
修改JVM堆大小方式:
找到Idea安装目录下的-->bin-->idea.exe.vmoptions
-server
-Xms128m //堆初始大小
-Xmx512m //最大堆内存
-XX:ReservedCodeCacheSize=240m
-XX:+UseConcMarkSweepGC //指定GC
-XX:SoftRefLRUPolicyMSPerMB=50-ea
-XX:CICompilerCount=2-Dsun.io.useCanonPrefixCache=false
-Djdk.http.auth.tunneling.disabledSchemes=""
-XX:+HeapDumpOnOutOfMemoryError
-XX:-OmitStackTraceInFastThrow
-Djdk.attach.allowAttachSelf=true
-Dkotlinx.coroutines.debug=off
-Djdk.module.illegalAccess.silent=true
堆配置
-Xms:初始堆大小
-Xmx:最大堆大小
-XX:NewSize=n: 设置年轻代大小
-XX:NewRatio=n: 设置年轻代和年老代的比值,
如:为3表示年轻代和年老代比值为1:3,年轻代占堆内存的1/4
-XX:SurvivorRatio=n: 年轻代中Eden区与两个Survivor区的比值。
注意Survivor区有两个。如3表示Eden:3 Survivor:2, 一个Survivor区占整个年轻代的1/5
-XX:MaxPermSize=n:设置永久代大小
永久代:元空间边栏推荐
猜你喜欢

4 * 4 * 4 Light Cube production and sharing

Expérience 5 segmentation et description des images

实验三 Servlet 相关技术

4*4*4光立方制作分享
![class path resource [xxx.properties] cannot be opened because it does not exist](/img/e3/5e5a568dbf2fcceae8b2d4a7249763.png)
class path resource [xxx.properties] cannot be opened because it does not exist

生成器模式的应用

npm ERR! cb() never called 处理办法

STM32 reads the data value of biaxial remote sensing

关于线程切换问题的一些思考总结

LCD1602 display key position
随机推荐
JUST k
Experiment 5 image segmentation and description
架构师进阶,微服务设计与治理的 16 条常用原则
Registration form practical skills [continuous update]
P1085 [noip2004 popularity group first question] unhappy Jinjin ← simulation question
Redis宕机日志分析
Experiment 4 image restoration and geometric correction
Ultrasonic ranging OLED display
OLED clock
Buckle practice - 20 rain II
损失函数与极大似然估计的联系 | 交叉熵的理解
CentOS7.9安装MySQL8详细步骤
软件质量保证与测试随堂练习
Lucas theorem
Repent of greed stonk
一文读懂软件测试的常见分类
Experiment 1 basic image transformation
npm ERR! cb() never called 处理办法
Course design of traffic light single chip microcomputer
实验一 图像基本变换