review (S) for 7032129: Native memory usage grow unexpectedly for vm/oom/*InternedString tests
Keith McGuigan
keith.mcguigan at oracle.com
Thu Mar 31 11:35:24 PDT 2011
Looks good.
On Mar 31, 2011, at 2:00 PM, Tom Rodriguez wrote:
> http://cr.openjdk.java.net/~never/7032129
>
> 7032129: Native memory usage grow unexpectedly for vm/oom/
> *InternedString tests
> Reviewed-by:
>
> StringTable::verify uses as_unicode_string to verify the hash code we
> keep in the table but the only resource mark is outside the loop.
> This means that verification makes a copy of the entire StringTable in
> a resource area. Now that interned strings aren't in perm the
> StringTable can become as large as the Java heap which means
> verification can overflow the address space. The fix is to compute
> the hash directly from the char[] instead of making a copy. I moved
> the hash_string logic into java_lang_String and updated the users
> appropriately. Tested with test case that allocates interned strings
> until we run out of heap.
>
More information about the hotspot-dev
mailing list