RFR(M) 8186834:Expanding old area without full GC in parallel GC
David Holmes
david.holmes at oracle.com
Tue Aug 29 06:36:12 UTC 2017
Hi Michihiro,
Please note that adding a new flag like this requires a Compatibility
and Specification Review request (CSR) [1] to be created and approved
before any code changes can be pushed. From the bug click "More" and
select "Create CSR".
Thanks,
David
[1] https://wiki.openjdk.java.net/display/csr/Main
On 29/08/2017 1:20 AM, Michihiro Horie wrote:
>
> Dear all,
>
> Would you please review the following change?
> bug: https://bugs.openjdk.java.net/browse/JDK-8186834
> webrev: http://cr.openjdk.java.net/~mhorie/8186834/webrev.00/
>
> In parallel GC, old area is expanded only after a full GC occurs.
> I am wondering if we could give an option to expand old area without full
> GC. So, I added an option
> UseAdaptiveGenerationSizePolicyBeforeMajorCollection.
>
> Following is a simple micro benchmark I used to see the benefit of this
> change.
> As a result, pause time of full GC reduced by 30%. Full GC count reduced by
> 54%.
> Elapsed time reduced by 7%.
>
> import java.util.HashMap;
> import java.util.Map;
> public class HeapExpandTest {
> static Map<Integer, byte[]> map = new HashMap<>();
> public static void main(String[] args) throws Exception {
> long start = System.currentTimeMillis();
> for (int i = 0; i < 2200; ++i) {
> map.put(i, new byte[1024*1024]); // 1MB
> }
> System.out.println("elapsed= " + (System.currentTimeMillis() - start));
> }
> }
>
> JVM options: -XX:+UseParallelGC -XX:+UseAdaptiveSizePolicy
> -XX:ParallelGCThreads=8 -Xms64m -Xmx3g
> -XX:+UseAdaptiveGenerationSizePolicyBeforeMajorCollection
>
>
> Best regards,
> --
> Michihiro,
> IBM Research - Tokyo
>
More information about the hotspot-dev
mailing list