Usage:
You can set the percentage of heap that you can to waste with:
-XX:G1HeapWastePercent=xxx, where xxx is the desired percent.
Examples:
To set the percent to 10% use:
-XX:G1HeapWastePercent=10
Description:
G1 (Garbage First) GC is designed for apps in multi-processor environments with large memory space (more than 4GB). It is available from the JDK7 Update 4. Unlike other collectors, the G1 collector partitions the heap into a set of equal-sized heap regions (usually 1MB to 32MB) chunks, prioritizes them, and then performs the garbage collection on those chunks based on the priority. We can tune G1 with additional options, one of them is G1HeapWastePercent the percentage of heap that you're willing to waste. The Java HotSpot VM doesn't initiate the mixed garbage collection cycle when the reclaimable percentage is less than the heap waste percentage.
Default Value:
Default value is 5%
Errors:
None
Arguments related:
TODO link UseG1GC , MaxHeapSize, MinHeapFreeRatio, MaxHeapFreeRatio, Xmx, Xms, NewSize
Related Posts:
- Quick start on Java GC
- Garbage collection tuning
- Garbage collectors documentation
- Quick start on Java GC
NOTE:
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.
Edit your Comment