RFR 8038212: Method::is_valid_method() check has performance regression impact for stackwalking
Mikael Gerdin
mikael.gerdin at oracle.com
Tue May 13 10:33:59 UTC 2014
Hi Coleen,
On Monday 12 May 2014 20.19.15 Coleen Phillimore wrote:
> Summary: Only prune metaspace virtual spaces at safepoint so walking
> them is safe outside a safepoint.
>
> Walking class loader data graph for contains is really slow for
> applications like nashorn that has a lot of class loader data.
>
> Tested with nsk.quick.testlist, jtreg tests, and jck tests. Also ran
>
> open webrev at http://cr.openjdk.java.net/~coleenp/8038212/
> bug link https://bugs.openjdk.java.net/browse/JDK-8038212
Thanks for taking care of this fix.
I think the idea of deferring CLDG::purge to the next safepoint cleanup is
sound.
I like the removal of CLDG::contains since it makes more sense to ask
Metaspace straight up.
I have a small question about the test you added:
3798 static void test_contains() {
3799 // Test that all the methods in the CLDG are contained
3800 ClassLoaderDataGraph::methods_do(assert_contains);
3801 }
Have we always allocated methods at this point in the VM startup?
Should we also test CLDG::classes_do to make sure it works for the compressed
class space?
/Mikael
>
> Marcus L. tested it with nashorn tests.
>
> Thanks,
> Coleen
More information about the hotspot-dev
mailing list