G1 "to-space exhausted" causes used heap space to increase?

Yu Zhang yu.zhang at oracle.com
Mon Mar 2 22:44:06 UTC 2015


Christopher,


        8. What is 'to-space exhausted'?  Why it is slow? How to avoid it?

'to-space exhausted' happens when there is not enough space to copy to 
during evacuation.  It is slow because g1 has to do a lot of work to 
make sure the heap is in a ready-to-use state.  There are several ways 
you can try to avoid it.  Trigger the mixed gc earlier by decreasing 
-XX:InitiatingHeapOccupancyPercent (default 45), adjust Young Gen size, 
increase G1ReservePercent, etc.  There is no one size fits all tuning.

 From the log snip you posted, my guess is most of the time the objects 
die in young gen.  But some times they live longer and promoted to old 
gen.  But there is not enough space in old gen.

Thanks,
Jenny

On 3/2/2015 10:52 AM, Christopher Berner wrote:
> We're just running with the default IHOP
>
> On Mon, Mar 2, 2015 at 10:15 AM, Simone Bordet 
> <simone.bordet at gmail.com <mailto:simone.bordet at gmail.com>> wrote:
>
>     Hi,
>
>     On Mon, Mar 2, 2015 at 6:44 PM, Christopher Berner
>     <christopherberner at gmail.com <mailto:christopherberner at gmail.com>>
>     wrote:
>     > Hello,
>     >
>     > I work on the Presto project
>     (https://github.com/facebook/presto) and am
>     > trying to understand the behavior of G1. We run a 45GB heap on
>     the worker
>     > machines with "-XX:G1HeapRegionSize=32M", and it works smoothly,
>
>     Just out of curiosity, you seem to have IHOP=45% and an eden that is
>     55% of the heap (25 GiB out of 45 GiB).
>     Is there any reason why you keep IHOP this low or you're just running
>     with defaults ?
>
>     To the hotspot gc experts, is there any way to limit the Eden size
>     without impacting on the ergonomics ?
>     Does -XX:MaxNewSize impact ergonomics ?
>
>     --
>     Simone Bordet
>     http://bordet.blogspot.com
>     ---
>     Finally, no matter how good the architecture and design are,
>     to deliver bug-free software with optimal performance and reliability,
>     the implementation technique must be flawless.  Victoria Livschitz
>
>
>
>
> _______________________________________________
> hotspot-gc-use mailing list
> hotspot-gc-use at openjdk.java.net
> http://mail.openjdk.java.net/mailman/listinfo/hotspot-gc-use

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/hotspot-gc-use/attachments/20150302/dd2144b6/attachment.html>


More information about the hotspot-gc-use mailing list