Mercurial > hg > graal-jvmci-8
diff src/share/vm/classfile/systemDictionary.cpp @ 20350:c3990b8c710e hs25.40-b07
8054402: "klass->is_loader_alive(_is_alive)) failed: must be alive" for anonymous classes
Summary: Because anonymous classes are not in the system dictionary, we have to set 'unloading_occurred' based on 'CLDG::do_unloading()'. Added jtreg test.
Reviewed-by: kvn, coleenp
author | thartmann |
---|---|
date | Mon, 25 Aug 2014 08:20:17 +0200 |
parents | 2c6ef90f030a |
children | 6e0cb14ce59b |
line wrap: on
line diff
--- a/src/share/vm/classfile/systemDictionary.cpp Thu Aug 21 14:48:49 2014 -0700 +++ b/src/share/vm/classfile/systemDictionary.cpp Mon Aug 25 08:20:17 2014 +0200 @@ -1662,10 +1662,9 @@ // Note: anonymous classes are not in the SD. bool SystemDictionary::do_unloading(BoolObjectClosure* is_alive) { // First, mark for unload all ClassLoaderData referencing a dead class loader. - bool has_dead_loaders = ClassLoaderDataGraph::do_unloading(is_alive); - bool unloading_occurred = false; - if (has_dead_loaders) { - unloading_occurred = dictionary()->do_unloading(); + bool unloading_occurred = ClassLoaderDataGraph::do_unloading(is_alive); + if (unloading_occurred) { + dictionary()->do_unloading(); constraints()->purge_loader_constraints(); resolution_errors()->purge_resolution_errors(); }