Profile Image

What is SurvivorRatio:- XX:SurvivorRatio?

What is SurvivorRatio: -XX:SurvivorRatio? Have you used this JVM argument before? What are the pros & cons of using this Java argument? Can you share your perspective/experience in using this JVM argument?

  • jvm-argument

  • xx-survivorratio

  • x-survivorratio

Please Sign In or to post your comment or answer

Profile Image

Pavel Khodakovsky



-XX:SurvivorRatio=<size>, where size – is a number used in proportion between eden and survivor space 1:size, meaning each survivor space will be 1/size of the size of eden.




Set survivorRatio to 5:


java -XX:SurvivorRatio=5




We can use the option -XX:SurvivorRatio to tune the size of the survivor spaces, but often this isn't important for performance. If survivor spaces are too small, then the copying collection overflows directly into the old generation. If survivor spaces are too large, then they are uselessly empty. At each garbage collection, the virtual machine chooses a threshold number, which is the number of times an object can be copied before it isold. This threshold is chosen to keep the survivors half full.


Default Value:


Default value for -XX: SurvivorRatio is dependent on JVM, for instance default option for the 64-bit Solaris operating system (SPARC Platform Edition) is 8.






Arguments related:


TODO link MinHeapFreeRatio, MaxHeapFreeRatio, Xmx, Xms


Related Posts:



If you have additional comments, interesting experiences or even point of disagreement with this JVM argument description, please leave a comment. Your insights will help the entire 10+ million java developer community to develop one standard source of documentation for all the JVM arguments.

Got something else on mind? Post Your Question

Not the answer you're looking for? Browse other questions tagged
  • jvm-argument

  • xx-survivorratio

  • x-survivorratio