`
fly_hyp
  • 浏览: 305746 次
  • 性别: Icon_minigender_1
  • 来自: 合肥
社区版块
存档分类
最新评论

sun jvm hotspot 参数

    博客分类:
  • Java
阅读更多
http://java.sun.com/javase/technologies/hotspot/vmoptions.jsp

Behavioral Options

Option and Default Value
Description
-XX:-AllowUserSignalHandlers Do not complain if the application installs signal handlers. (Relevant to Solaris and Linux only.)


-XX:AltStackSize=16384 Alternate signal stack size (in Kbytes). (Relevant to Solaris only, removed from 5.0.)


-XX:-DisableExplicitGC Disable calls to System.gc(), JVM still performs garbage collection when necessary.


-XX:+FailOverToOldVerifier Fail over to old verifier when the new type checker fails. (Introduced in 6.)


-XX:+HandlePromotionFailure The youngest generation collection does not require a guarantee of full promotion of all live objects. (Introduced in 1.4.2 update 11) [5.0 and earlier: false.]


-XX:+MaxFDLimit Bump the number of file descriptors to max. (Relevant  to Solaris only.)


-XX:PreBlockSpin=10 Spin count variable for use with -XX:+UseSpinning. Controls the maximum spin iterations allowed before entering operating system thread synchronization code. (Introduced in 1.4.2.)


-XX:-RelaxAccessControlCheck Relax the access control checks in the verifier. (Introduced in 6.)


-XX:+ScavengeBeforeFullGC Do young generation GC prior to a full GC. (Introduced in 1.4.1.)


-XX:+UseAltSigs Use alternate signals instead of SIGUSR1 and SIGUSR2 for VM internal signals. (Introduced in 1.3.1 update 9, 1.4.1. Relevant to Solaris only.)


-XX:+UseBoundThreads Bind user level threads to kernel threads. (Relevant to Solaris only.)


-XX:-UseConcMarkSweepGC Use concurrent mark-sweep collection for the old generation. (Introduced in 1.4.1)


-XX:+UseGCOverheadLimit Use a policy that limits the proportion of the VM's time that is spent in GC before an OutOfMemory error is thrown. (Introduced in 6.)


-XX:+UseLWPSynchronization Use LWP-based instead of thread based synchronization. (Introduced in 1.4.0. Relevant to Solaris only.)


-XX:-UseParallelGC Use parallel garbage collection for scavenges. (Introduced in 1.4.1)


-XX:-UseParallelOldGC Use parallel garbage collection for the full collections. Enabling this option automatically sets -XX:+UseParallelGC. (Introduced in 5.0 update 6.)


-XX:-UseSerialGC Use serial garbage collection. (Introduced in 5.0.)


-XX:-UseSpinning Enable naive spinning on Java monitor before entering operating system thread synchronizaton code. (Relevant to 1.4.2 and 5.0 only.) [1.4.2, multi-processor Windows platforms: true]


-XX:+UseTLAB Use thread-local object allocation (Introduced in 1.4.0, known as UseTLE prior to that.) [1.4.2 and earlier, x86 or with -client: false]


-XX:+UseSplitVerifier Use the new type checker with StackMapTable attributes. (Introduced in 5.0.)[5.0: false]


-XX:+UseThreadPriorities Use native thread priorities.


-XX:+UseVMInterruptibleIO Thread interrupt before or with EINTR for I/O operations results in OS_INTRPT. (Introduced in 6. Relevant to Solaris only.)



Back to Options


--------------------------------------------------------------------------------

Performance Options

Option and Default Value
Description
-XX:+AggressiveOpts Turn on point performance compiler optimizations that are expected to be default in upcoming releases. (Introduced in 5.0 update 6.)


-XX:CompileThreshold=10000 Number of method invocations/branches before compiling [-client: 1,500]


-XX:LargePageSizeInBytes=4m Sets the large page size used for the Java heap. (Introduced in 1.4.0 update 1.) [amd64: 2m.]


-XX:MaxHeapFreeRatio=70 Maximum percentage of heap free after GC to avoid shrinking.


-XX:MaxNewSize=size Maximum size of new generation (in bytes). Since 1.4, MaxNewSize is computed as a function of NewRatio. [1.3.1 Sparc: 32m; 1.3.1 x86: 2.5m.]


-XX:MaxPermSize=64m Size of the Permanent Generation.  [5.0 and newer: 64 bit VMs are scaled 30% larger; 1.4 amd64: 96m; 1.3.1 -client: 32m.]


-XX:MinHeapFreeRatio=40 Minimum percentage of heap free after GC to avoid expansion.


-XX:NewRatio=2 Ratio of new/old generation sizes. [Sparc -client: 8; x86 -server: 8; x86 -client: 12.]-client: 4 (1.3) 8 (1.3.1+), x86: 12]


-XX:NewSize=2.125m Default size of new generation (in bytes) [5.0 and newer: 64 bit VMs are scaled 30% larger; x86: 1m; x86, 5.0 and older: 640k]


-XX:ReservedCodeCacheSize=32m Reserved code cache size (in bytes) - maximum code cache size. [Solaris 64-bit, amd64, and -server x86: 48m; in 1.5.0_06 and earlier, Solaris 64-bit and and64: 1024m.]


-XX:SurvivorRatio=8 Ratio of eden/survivor space size [Solaris amd64: 6; Sparc in 1.3.1: 25; other Solaris platforms in 5.0 and earlier: 32]


-XX:TargetSurvivorRatio=50 Desired percentage of survivor space used after scavenge.


-XX:ThreadStackSize=512 Thread Stack Size (in Kbytes). (0 means use default stack size) [Sparc: 512; Solaris x86: 320 (was 256 prior in 5.0 and earlier); Sparc 64 bit: 1024; Linux amd64: 1024 (was 0 in 5.0 and earlier); all others 0.]


-XX:+UseBiasedLocking Enable biased locking. For more details, see this tuning example. (Introduced in 5.0 update 6.) [5.0: false]


-XX:+UseFastAccessorMethods Use optimized versions of Get<Primitive>Field.


-XX:-UseISM Use Intimate Shared Memory. [Not accepted for non-Solaris platforms.] For details, see Intimate Shared Memory.


-XX:+UseLargePages Use large page memory. (Introduced in 5.0 update 5.) For details, see Java Support for Large Memory Pages.


-XX:+UseMPSS Use Multiple Page Size Support w/4mb pages for the heap. Do not use with ISM as this replaces the need for ISM. (Introduced in 1.4.0 update 1, Relevant to Solaris 9 and newer.) [1.4.1 and earlier: false]


-XX:+StringCache Enables caching of commonly allocated strings.


-XX:AllocatePrefetchLines=1 Number of cache lines to load after the last object allocation using prefetch instructions generated in JIT compiled code. Default values are 1 if the last allocated object was an instance and 3 if it was an array.


-XX:AllocatePrefetchStyle=1 Generated code style for prefetch instructions.
0 - no prefetch instructions are generate*d*,
1 - execute prefetch instructions after each allocation,
2 - use TLAB allocation watermark pointer to gate when prefetch instructions are executed.



Back to Options


--------------------------------------------------------------------------------

Debugging Options

Option and Default Value
Description
-XX:-CITime Prints time spent in JIT Compiler. (Introduced in 1.4.0.)


-XX:ErrorFile=./hs_err_pid<pid>.log If an error occurs, save the error data to this file. (Introduced in 6.)


-XX:-ExtendedDTraceProbes Enable performance-impacting dtrace probes. (Introduced in 6. Relevant to Solaris only.)


-XX:HeapDumpPath=./java_pid<pid>.hprof Path to directory or filename for heap dump. Manageable. (Introduced in 1.4.2 update 12, 5.0 update 7.)


-XX:-HeapDumpOnOutOfMemoryError Dump heap to file when java.lang.OutOfMemoryError is thrown. Manageable. (Introduced in 1.4.2 update 12, 5.0 update 7.)


-XX:OnError="<cmd args>;<cmd args>" Run user-defined commands on fatal error. (Introduced in 1.4.2 update 9.)


-XX:OnOutOfMemoryError="<cmd args>;
<cmd args>" Run user-defined commands when an OutOfMemoryError is first thrown. (Introduced in 1.4.2 update 12, 6)


-XX:-PrintClassHistogram Print a histogram of class instances on Ctrl-Break. Manageable. (Introduced in 1.4.2.) The jmap -histo command provides equivalent functionality.


-XX:-PrintConcurrentLocks Print java.util.concurrent locks in Ctrl-Break thread dump. Manageable. (Introduced in 6.) The jstack -l command provides equivalent functionality.


-XX:-PrintCommandLineFlags Print flags that appeared on the command line. (Introduced in 5.0.)


-XX:-PrintCompilation Print message when a method is compiled.


-XX:-PrintGC Print messages at garbage collection. Manageable.


-XX:-PrintGCDetails Print more details at garbage collection. Manageable. (Introduced in 1.4.0.)


-XX:-PrintGCTimeStamps Print timestamps at garbage collection. Manageable (Introduced in 1.4.0.)


-XX:-PrintTenuringDistribution Print tenuring age information.


-XX:-TraceClassLoading Trace loading of classes.


-XX:-TraceClassLoadingPreorder Trace all classes loaded in order referenced (not loaded). (Introduced in 1.4.2.)


-XX:-TraceClassResolution Trace constant pool resolutions. (Introduced in 1.4.2.)


-XX:-TraceClassUnloading Trace unloading of classes.


-XX:-TraceLoaderConstraints Trace recording of loader constraints. (Introduced in 6.)


-XX:+PerfSaveDataToFile Saves jvmstat binary data on exit.

分享到:
评论

相关推荐

    JVM Hotspot实现源码

    《OpenJDK中的JVM Hotspot实现源码解析》 在Java世界中,JVM(Java Virtual Machine)是运行Java程序的关键组件,它负责将字节码解释执行或即时编译为机器码,使得Java具备跨平台的能力。Hotspot是Oracle JDK和...

    Sun JVM原理与内存管理

    - **Sun Hotspot 对 JVM 堆采用分代管理**: - **新生代** (Young Generation):包含 Eden 和 Survivor 区域 (S0/S1)。 - **老年代** (Old Generation):长期存活的对象将被转移到这里。 - **分代策略**:利用...

    借HSDB来探索HotSpot VM的运行时数据.gist1

    %JAVA_HOME%/lib/sa-jdi.jar sun.jvm.hotspot.HSDB`则启动HSDB。 HSDB是HotSpot虚拟机的调试桥,它可以连接到正在运行的JVM并提供对堆、栈、方法等的检查。在HSDB会话中,`universe`命令显示了堆的参数和状态。这里...

    Sun Hotspot V1.6.0 JVM GC PPT.pdf

    ### Sun Hotspot V1.6.0 JVM GC详解 #### 一、JVM结构与GC基础知识 ##### 1.1 JVM内存结构概述 Java虚拟机(JVM)内存主要分为以下几个部分: - **程序计数器(PC Register)**:记录当前线程所执行的字节码指令...

    JVM实用参数

    本文旨在总结JVM的相关知识,重点介绍Sun/Oracle HotSpot JVM中的实用参数及其应用场景。JVM(Java虚拟机)是Java语言的核心组成部分之一,它负责运行Java字节码,并提供了一个运行时环境,确保Java应用程序能够跨...

    Java HotSpot虚拟机的部分参数翻译

    本文将深入探讨Java HotSpot虚拟机的部分参数及其作用,帮助开发者更好地理解和调整JVM的配置,以优化应用程序性能。 一、JVM启动参数类型 Java HotSpot虚拟机的参数可以分为三类: 1. 标准选项(-X):由Sun ...

    java JVM详解

    为了优化 SUN JVM 的性能,开发者可以调整各种参数,例如设置堆大小、启用或禁用特定的垃圾回收算法等。这些参数可以通过命令行选项传递给 JVM。 ##### 2.5 JVM 简单理解 - **Java 栈**:用于存储线程级别的局部...

    java查看sun包源码-monitor:java生产环境内存调优(包括jvm参数类型,JVM的参数类型jinfo&jps(参数和进程查看)j

    java查看sun包源码 主要内容包括 :blue_heart: :blue_heart: :blue_heart: :blue_heart: :blue_heart: :blue_heart: jvm参数类型:alien: jinfo & jps(参数和进程查看):alien: jstat(类加载、垃圾收集、JIT 编译):...

    JVM演讲PPT分享

    Hotspot是Sun(现在是Oracle)公司开发的JVM实现,被广泛应用于Java开发和应用之中。它以高性能和垃圾回收效率著称,特别是在利用了适应性技术,使得它能够自动选择使用哪种垃圾回收器以及调整垃圾回收的参数,从而...

    JVM基础.doc

    #### 一、JVM概述与HotSpot简介 Java虚拟机(JVM)是Java技术的核心组成部分之一,它为Java程序提供了运行时环境。本节将详细介绍JVM的基本概念及其核心技术——HotSpot。 **HotSpot VM** 是Oracle公司提供的一个高...

    [百度网盘] HotSpot实战[完整版][带书签].pdf

    - HotSpot是由Sun Microsystems开发的一款高性能Java虚拟机,后来随着Sun被Oracle收购而成为Oracle的一部分。 - 它的设计理念是“预测热点代码”,通过动态编译技术对热点代码进行优化,从而显著提升运行时性能。 ...

    ebs原版本jvm.dll文件

    - **hotspot**:这指的是 HotSpot VM,是 Sun Microsystems 开发的一种高性能的 JVM 实现,后来由 Oracle 继承并继续维护。 ### 4. “老版本”含义及其影响 提到该 `jvm.dll` 文件为“老版本”,意味着它可能不是...

    JVM详解及调优

    Sun JVM是早期最流行的JVM实现之一,它的设计基于HotSpot VM,具有高性能的特点。 **2.3 Sun JVM内存管理(优化)** - **堆(Heap)**: 用于存放所有Java对象实例和数组的空间。堆是所有线程共享的,因此需要处理...

    jdk sun 开头的源码

    例如,`sun.jvm.hotspot`子包提供了一些用于分析和调试HotSpot JVM的工具,这对于性能优化和故障排查非常有用。 4. **编译器和类加载器**:`sun.compile`和`sun.misc`包提供了对Java编译和类加载的支持。`sun.misc....

    HotSpot实战

    HotSpot 是一款高性能的 Java 虚拟机 (JVM),由 Sun Microsystems 开发并随后被 Oracle 公司收购。HotSpot 虚拟机是当前最流行的 JVM 实现之一,广泛应用于企业级应用服务器、桌面应用程序以及其他需要运行 Java ...

    实战Hot Spot JVM GC

    通过JMX相关参数,如-Dcom.sun.management.jmxremote.port等,可以在远程监控和管理JVM。 在GC监控方面,除了使用JMX参数外,还可以使用-Xloggc:文件参数来记录GC日志,并通过-XX:+PrintGCDetails等参数打印GC的...

    JVM历史发展和内存回收笔记

    2. **HotSpot VM**:1997年,Sun公司收购了HotSpot VM,这是一个具有动态编译能力的JVM,能够根据程序运行情况优化代码,显著提升了性能。HotSpot后来成为了Java SE的标准JVM。 3. **Java 2 Platform, Standard ...

    jvm原理及调优

    在Sun HotSpot JVM中,为了提高对象分配的速度,引入了TLAB(Thread Local Allocation Buffer)的概念。TLAB是每个线程私有的缓冲区,用于快速分配对象。当对象过大或TLAB已满时,JVM会直接在堆上分配。 - **新生代...

Global site tag (gtag.js) - Google Analytics