What values do use for MaxTenuringThreshold?

James Nichols jamesnichols3 at gmail.com
Fri May 30 13:37:10 UTC 2008


Hey Tony,

A while back I exchanged some messages about the tenuring threshold on this
list, see:

http://mail.openjdk.java.net/pipermail/hotspot-gc-use/2008-January/000027.html

My MaxTenuringThreshold at the time was set to 30, but if you look at the
plots attached to the email thread above, you can see it never went above
16.  I had MTT set so high since I had a lot of short-lived data that would
get promoted and GC'd when the next tenured area collection ran, which to me
meant they were getting promoted too soon.   I was using 1.5.0_12 and was
always on it, so the change in bit size for the age value wasn't that big of
deal, I guess.  I was somewhat perplexed at the time as to why the threshold
never went above 16 and now I know why.  I currently have it set to 4 (along
with a modified survivor space size), since I had a lot of unnecessary
copying and the premature promotion issues discussed in the above post.

My experience has shown that having a really high MTT leads to a ton of
extra copying.   Likewise, I'm not sure in what circumstances NeverTenure
would be a good idea.  The whole point of generational garbage collection is
to get junk that sticks around a while out of the hot area of memory, isn't
it?  Both of these settings seem to indicate that you'ld be better off using
non generational GC.

For what it's worth, if I am working with a new application that has gc
problems on a jvm that hasn't been tuned, I would set MTT to 4 with CMS and
see how it worked and iterate from there.

In Summary, current MTT=4.  As to the change impacting performance, I'm not
sure since I never ran this particular app on a rev of the JVM that old.

Jim


On Thu, May 29, 2008 at 4:52 PM, Tony Printezis <tony.printezis at sun.com>
wrote:

> (this is a follow-up to a discussion on the hotspot-gc-dev list)
>
> We're trying to take a quick poll on what values you use for
> MaxTenuringThreshold and whether the decrease in age field size from 5
> to 4 bits (from 1.5u6) seemed to have affected the performance of your app.
>
> This is the thread, if you're interested:
>
> http://mail.openjdk.java.net/pipermail/hotspot-gc-dev/2008-May/000309.html
>
> Tony, HS GC Group
>
> --
> ----------------------------------------------------------------------
> | Tony Printezis, Staff Engineer    | Sun Microsystems Inc.          |
> |                                   | MS BUR02-311                   |
> | e-mail: tony.printezis at sun.com    | 35 Network Drive               |
> | office: +1 781 442 0998 (x20998)  | Burlington, MA01803-0902, USA  |
> ----------------------------------------------------------------------
> e-mail client: Thunderbird (Solaris)
>
>
> _______________________________________________
> 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: <https://mail.openjdk.org/pipermail/hotspot-gc-dev/attachments/20080530/421da1d1/attachment.htm>
-------------- next part --------------
_______________________________________________
hotspot-gc-use mailing list
hotspot-gc-use at openjdk.java.net
http://mail.openjdk.java.net/mailman/listinfo/hotspot-gc-use


More information about the hotspot-gc-dev mailing list