RFR: JDK-8148736: Let the G1 heap transition log regions instead of bytes

kirk.pepperdine at gmail.com kirk.pepperdine at gmail.com
Mon Feb 1 15:30:53 UTC 2016


Hi Bengt,

> 
> We know the reason for the inaccurate measurements. I had some pretty detailed descriptions of it in JDK-8147976, but I now realize that I didn't make them publicly viewable since I was using an internal benchmark for the investigation. However, I don't think there is anything that can't be public about it, so I changed the comments to be visible. Please take a new look at the bug report for a detailed descriptions of the problem.
> 
> https://bugs.openjdk.java.net/browse/JDK-8147976

Thank you for making this public. 
> 
> Basically the conclusion is that there is no fast way to get the correct numbers. There is a way to get the exact numbers, but that involves iterating over all heap regions, which can potentially take some time. My proposed patch adds the exact logging at trace level. This makes it possible to use that if you are tracking down a particular problem but you can use the fast logging to get a rough number in normal execution.

So my understanding of the thread suggests that this decision is based on a very specialized condition created by this benchmark that wastes a lot of memory. Again, it is my opinion that occupancy are important and that relying on an estimate based on region size is simply far too course a measure for 1M regions and only gets worse as region size increases. That’s not accounting for the inaccuracy due to waste. I have a number of experimental analytics that will tolerate a fair amount of “noise” in the data when using K granularity. Using M granularity is and issue that this gives us even worse precision than that.

If this is simply a matter of time, as I’ve mentioned before, I’m quite happy to pitch to help get it right.

Kind regards,
Kirk




More information about the hotspot-gc-dev mailing list