HotSpot在不同环境里的VM参数默认值参考

暂时就放个gist链接出来:>> https://gist.github.com/827140 <<
多数参数的意义在这里可以查到: globals.hpp

Windows测试环境:
OS: Windows XP Build 2600 Service Pack 3

CPU:total 2 (2 cores per cpu, 1 threads per core) family 6 model 23 stepping 10, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3, sse4.1

Memory: 4k page, physical 3405352k(2067228k free), swap 5334424k(3848208k free)

vm_info: Java HotSpot(TM) Client VM (19.0-b09) for windows-x86 JRE (1.6.0_23-b05), built on Nov 12 2010 15:00:43 by "java_re" with MS VC++ 7.1 (VS2003)

OS: Windows XP Build 2600 Service Pack 3

CPU:total 2 (2 cores per cpu, 1 threads per core) family 6 model 23 stepping 10, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3, sse4.1

Memory: 4k page, physical 3405352k(2043728k free), swap 5334424k(3801564k free)

vm_info: Java HotSpot(TM) Server VM (19.0-b09) for windows-x86 JRE (1.6.0_23-b05), built on Nov 12 2010 14:54:05 by "java_re" with MS VC++ 7.1 (VS2003)


Linux x64测试环境:
OS:Red Hat Enterprise Linux Server release 5.4 (Tikanga)

uname:Linux 2.6.18-164.el5xen #1 SMP Tue Aug 18 15:59:52 EDT 2009 x86_64
libc:glibc 2.5 NPTL 2.5 
rlimit: STACK 10240k, CORE 0k, NPROC 28064, NOFILE 1024, AS infinity
load average:0.04 0.02 0.00

/proc/meminfo:
MemTotal:      3584000 kB
MemFree:       1742760 kB
Buffers:        342260 kB
Cached:        1122924 kB
SwapCached:       2076 kB
Active:         694568 kB
Inactive:       905416 kB
HighTotal:           0 kB
HighFree:            0 kB
LowTotal:      3584000 kB
LowFree:       1742760 kB
SwapTotal:     1052248 kB
SwapFree:      1045628 kB
Dirty:              20 kB
Writeback:           0 kB
AnonPages:      133980 kB
Mapped:          17656 kB
Slab:           144916 kB
PageTables:       2540 kB
NFS_Unstable:        0 kB
Bounce:              0 kB
CommitLimit:   2844248 kB
Committed_AS:   268736 kB
VmallocTotal: 34359738367 kB
VmallocUsed:       700 kB
VmallocChunk: 34359737667 kB


CPU:total 4 (4 cores per cpu, 1 threads per core) family 6 model 15 stepping 11, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3

/proc/cpuinfo:
processor	: 0
vendor_id	: GenuineIntel
cpu family	: 6
model		: 15
model name	: Intel(R) Xeon(R) CPU           E5320  @ 1.86GHz
stepping	: 11
cpu MHz		: 1861.913
cache size	: 4096 KB
physical id	: 0
siblings	: 1
core id		: 0
cpu cores	: 1
fpu		: yes
fpu_exception	: yes
cpuid level	: 10
wp		: yes
flags		: fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht syscall nx lm constant_tsc pni cx16 lahf_lm
bogomips	: 4656.41
clflush size	: 64
cache_alignment	: 64
address sizes	: 38 bits physical, 48 bits virtual
power management:

processor	: 1
vendor_id	: GenuineIntel
cpu family	: 6
model		: 15
model name	: Intel(R) Xeon(R) CPU           E5320  @ 1.86GHz
stepping	: 11
cpu MHz		: 1861.913
cache size	: 4096 KB
physical id	: 1
siblings	: 1
core id		: 0
cpu cores	: 1
fpu		: yes
fpu_exception	: yes
cpuid level	: 10
wp		: yes
flags		: fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht syscall nx lm constant_tsc pni cx16 lahf_lm
bogomips	: 4656.41
clflush size	: 64
cache_alignment	: 64
address sizes	: 38 bits physical, 48 bits virtual
power management:

processor	: 2
vendor_id	: GenuineIntel
cpu family	: 6
model		: 15
model name	: Intel(R) Xeon(R) CPU           E5320  @ 1.86GHz
stepping	: 11
cpu MHz		: 1861.913
cache size	: 4096 KB
physical id	: 2
siblings	: 1
core id		: 0
cpu cores	: 1
fpu		: yes
fpu_exception	: yes
cpuid level	: 10
wp		: yes
flags		: fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht syscall nx lm constant_tsc pni cx16 lahf_lm
bogomips	: 4656.41
clflush size	: 64
cache_alignment	: 64
address sizes	: 38 bits physical, 48 bits virtual
power management:

processor	: 3
vendor_id	: GenuineIntel
cpu family	: 6
model		: 15
model name	: Intel(R) Xeon(R) CPU           E5320  @ 1.86GHz
stepping	: 11
cpu MHz		: 1861.913
cache size	: 4096 KB
physical id	: 3
siblings	: 1
core id		: 0
cpu cores	: 1
fpu		: yes
fpu_exception	: yes
cpuid level	: 10
wp		: yes
flags		: fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht syscall nx lm constant_tsc pni cx16 lahf_lm
bogomips	: 4656.41
clflush size	: 64
cache_alignment	: 64
address sizes	: 38 bits physical, 48 bits virtual
power management:



Memory: 4k page, physical 3584000k(1742760k free), swap 1052248k(1045628k free)

vm_info: Java HotSpot(TM) 64-Bit Server VM (20.0-b08) for linux-amd64 JRE (1.6.0_25-ea-b01), built on Jan 27 2011 13:11:34 by "java_re" with gcc 3.2.2 (SuSE Linux)


====================================================================

一些参数的备注:

PrintClassHistogramBeforeFullGC (>= 6u18)
UseFPUForSpilling在支持SSE2或异常的系统上默认仍然是false的,但打开AggressiveOpts则会变为true
UseOprofile 留意一下这个参数,默认是false
MaxTenuringThreshold在使用CMS时的默认值会变成4

====================================================================

参数相关讨论:

JVM调优的"标准参数"的各种陷阱

你可能感兴趣的:(java)