Usage:
You can set the percentage for regions to be considered for inclusion in the collection set of mixed GCs with:
-XX:G1MixedGCLiveThresholdPercent=percent , where percent is the desired value in %.
Since:
Starting from JDK 7.
Examples:
This will instruct JVM to set 50% of regions to be considered for inclusion:
-XX:G1MixedGCLiveThresholdPercent=50
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. The G1 collector is designed for applications that:
- Can operate concurrently with applications threads like the CMS collector.
- Compact free space without lengthy GC induced pause times.
- Need more predictable GC pause durations.
- Do not want to sacrifice a lot of throughput performance.
- Do not require a much larger Java heap.
We can tune G1 with additional options, one of them is G1MixedGCLiveThresholdPercent. This flag sets the occupancy threshold for an old region to be included in a mixed garbage collection cycle.
This is an experimental flag. This setting replaces the -XX:G1OldCSetRegionLiveThresholdPercent setting.
Default Value:
Default is 85%.
Errors:
The value should be between 0 and 100.
Arguments related:
G1NewSizePercent, G1MaxNewSizePercent, UseG1GC, MinHeapFreeRatio, MaxHeapFreeRatio, DefaultMinNewGenPercent, G1ReservePercent, G1HeapWastePercent, G1MixedGCCountTarget, G1OldCSetRegionThresholdPercent
Related Posts:
Edit your Comment