Hi Jon --<br><br>While I am not familiar with all of the details of the new metaspaces implementation,<br>from my high level knowledge of how it works, the shape of the code changes here to address the bug looks good to me.<br>
(Although it would have been nice if one could have read the stack retrace of the JVM when the deadlock occurred, i<br>think such information was not in the public part of the bug report visible on <a href="http://bugs.sun.com">bugs.sun.com</a>.)<br>
<br>A somewhat orthogonal question:<br>Could you tell me if there is any a-priori limit that the JVM sets on the c-heap space used for the metadata?<br>If yes, can that limit be changed from the command-line? If there is no such a-priori limit, could you shed any light<br>
on a comparison of the memory footprint between the pre-NPG world and the new post-NPG world for<br>some benchmarks that exercise class load/unload etc.?<br><br>thanks!<br>-- ramki<br><br><div class="gmail_quote">On Mon, Sep 17, 2012 at 3:18 PM, Jon Masamitsu <span dir="ltr"><<a href="mailto:jon.masamitsu@oracle.com" target="_blank">jon.masamitsu@oracle.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I have one review (Thanks JohnCu). The change is straight forward<br>
but it is code that has problems in the past (GC_locker code) so any<br>
other reviews would be welcome.<span class="HOEnZb"><font color="#888888"><br>
<br>
Jon</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
On 09/16/12 20:09, Jon Masamitsu wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
NPG: nsk/sysdict/vm/stress/chain/<u></u>chain004 hangs intermittently<br>
<br>
The code that was doing a GC to find dead class loaders so that metadata<br>
could be freed does not correctly account for GC_locker activity (i.e., use<br>
of JNI critical sections which stall GC). Added code to recognize if<br>
a GC_locker is active and expand the Metaspace and allocate out of the<br>
expanded area. If the expansion cannot provide metadata, wait for<br>
the GC_locker to inactivate so that a GC can be done.<br>
<br>
<a href="http://cr.openjdk.java.net/%7Ejmasa/7197557/webrev.00/" target="_blank">http://cr.openjdk.java.net/~<u></u>jmasa/7197557/webrev.00/</a><br>
<br>
Note that there are three places in the different GC's that need to<br>
account for GC_locker activity. I am investigating whether this<br>
code can be unified.<br>
</blockquote>
</div></div></blockquote></div><br>