Strage jmap heap output for G1 on 32bit JVM
Jesper Wilhelmsson
jesper.wilhelmsson at oracle.com
Fri May 22 08:03:45 UTC 2015
Hi Jakub,
Awesome work! Thanks for taking the time to find the fix!
I'll work on getting it in to 8u60.
/Jesper
Jakub Kubryński skrev den 22/5/15 03:46:
> Hi Jesper,
>
> I've checked and the problem was fixed between jdk9-b02 and jdk9-b03 in
> changeset 5864:e9fc29d2e8ae (8031686: G1: assert(_hrs.max_length() ==
> _expansion_regions) failed)
>
> Best regards,
> Jakub
>
> 2015-05-21 19:23 GMT+02:00 Jesper Wilhelmsson <jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>:
>
> OK. One way to find what change that fixed this in 9 would be to go back in
> the 9 history and see where it starts to fail. I could do that if I had a
> reproducer. Is it an option for you to share your reproducer? If not I guess
> you can step back in the mercurial history on your side if you feel
> comfortable building the JDK locally.
>
> Once we find the fix we can backport it to 8u. We are slightly short on time
> though since 8u60 is ramping down right now.
>
> Thanks,
> /Jesper
>
>
> Jakub Kubryński skrev den 20/5/15 22:46:
>
> I've checked with latest JDK 9 and it's OK. However 8u60 still reports
> incorrect
> number of regions for Xmx2g. For -Xmx2046m it's OK and for -Xmx2047m there
> are 14336 regions reported and eden capacity is 15032385536
> <tel:15032385536> (14336.0MB).
>
> I don't know PrintHeapAtExit flag but I've added PrintHeapAtGC and it
> reported:
>
> Heap
> garbage-first heap total 125952K, used 99580K [0x66600000, 0x667001ec,
> 0xe6600000)
> region size 1024K, 62 young (63488K), 7 survivors (7168K)
> Metaspace used 29856K, capacity 30136K, committed 30208K,
> reserved 31024K
>
> Cheers,
> Kuba
>
>
> 2015-05-20 17:48 GMT+02:00 Jesper Wilhelmsson
> <jesper.wilhelmsson at oracle.com <mailto:jesper.wilhelmsson at oracle.com>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>>:
>
> FYI, I filed JDK-8080784 to cover this issue.
>
> https://bugs.openjdk.java.net/browse/JDK-8080784
>
> /Jesper
>
>
> Jakub Kubryński skrev den 20/5/15 16:50:
>
> Yes, I'll check it on latest Jdk9 and let you know.
>
> Best,
> Jakub
>
> 20 maj 2015 16:35 "Jesper Wilhelmsson"
> <jesper.wilhelmsson at oracle.com <mailto:jesper.wilhelmsson at oracle.com>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>>> napisał(a):
>
> Ok. I tried that as well but it didn't reproduce.
>
> After a closer look it seems as if it is the number of
> regions that
> is wrong
> and causes the huge free size reported. There have been a few
> changes in
> this area recently which may have fixed this issue.
>
> Is it possible to try your reproducer with a recent build
> of JDK 9
> or the
> latest version of 8u from the OpenJDK source repositories?
> /Jesper
>
>
> Jakub Kubryński skrev den 20/5/15 15:23:
>
> 64 bit Linux with 32bit JVM.
>
> Cheers,
> Jakub
>
> 20 maj 2015 15:18 "Jesper Wilhelmsson"
> <jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>
> <mailto:jesper.wilhelmsson at oracle.com
> <mailto:jesper.wilhelmsson at oracle.com>>>>> napisał(a):
>
> Hi,
>
> Does this reproduce every time?
> What platform is it?
>
> I have tried to reproduce this on 32bit linux but
> can't see
> anything weird
> there. It seems likely that there is a variable
> with the
> wrong type
> somewhere on the way. I'll see if I can find
> something.
> /Jesper
>
>
> Jakub Kubryński skrev den 15/5/15 17:22:
>
> Hi,
>
> I've just checked that on 32bit JVM (HotSpot
> 8u45)
> jmap reports
> strange
> region
> information for G1 collector. As you can see
> Xmx is
> set to 2G
> (which fits
> MaxHeapSize) but regions count (almost 15k) and
> capacity is
> incorrect.
> Any ideas
> why?
>
> Heap Configuration:
> MinHeapFreeRatio = 40
> MaxHeapFreeRatio = 70
> MaxHeapSize = 2147483648
> <tel:2147483648>
> <tel:2147483648 <tel:2147483648>> <tel:2147483648
> <tel:2147483648> <tel:2147483648 <tel:2147483648>>>
> <tel:2147483648 <tel:2147483648> <tel:2147483648
> <tel:2147483648>> <tel:2147483648 <tel:2147483648>
> <tel:2147483648 <tel:2147483648>>>> (2048.0MB)
> NewSize = 1048576 (1.0MB)
> MaxNewSize = 428867584
> (409.0MB)
> OldSize = 4194304 (4.0MB)
> NewRatio = 2
> SurvivorRatio = 8
> MetaspaceSize = 16777216 (16.0MB)
> CompressedClassSpaceSize = 1073741824
> (1024.0MB)
> MaxMetaspaceSize = 4294963200
> (4095.99609375MB)
> G1HeapRegionSize = 1048576 (1.0MB)
>
> Heap Usage:
> G1 Heap:
> regions = 14336
> capacity = 15032385536 <tel:15032385536>
> <tel:15032385536 <tel:15032385536>>
> <tel:15032385536 <tel:15032385536> <tel:15032385536
> <tel:15032385536>>> <tel:15032385536 <tel:15032385536> <tel:15032385536
> <tel:15032385536>>
> <tel:15032385536 <tel:15032385536> <tel:15032385536
> <tel:15032385536>>>> (14336.0MB)
> used = 76347888 (72.81101989746094MB)
> free = 14956037648
> (14263.188980102539MB)
> 0.5078893687043872% used
>
> --
> Best regards,
> Jakub Kubrynski
>
>
>
>
> --
> Best regards,
> Jakub Kubrynski
>
>
>
>
> --
> Best regards,
> Jakub Kubrynski
More information about the hotspot-gc-dev
mailing list