comparison src/share/vm/oops/klass.cpp @ 14190:ce86c36b8921

8029178: Parallel class loading test anonymous-simple gets SIGSEGV in Metaspace::contains Summary: Metaspace::contains cannot look at purged metaspaces while CMS concurrently deallocates them. Reviewed-by: mgerdin, sspitsyn, jmasa
author coleenp
date Tue, 07 Jan 2014 13:26:56 -0500
parents b2e698d2276c
children 48314d596a04
comparison
equal deleted inserted replaced
14189:1a899ea6b7ed 14190:ce86c36b8921
374 super->set_subklass(this); 374 super->set_subklass(this);
375 debug_only(verify();) 375 debug_only(verify();)
376 } 376 }
377 377
378 bool Klass::is_loader_alive(BoolObjectClosure* is_alive) { 378 bool Klass::is_loader_alive(BoolObjectClosure* is_alive) {
379 assert(ClassLoaderDataGraph::contains((address)this), "is in the metaspace");
380
381 #ifdef ASSERT 379 #ifdef ASSERT
382 // The class is alive iff the class loader is alive. 380 // The class is alive iff the class loader is alive.
383 oop loader = class_loader(); 381 oop loader = class_loader();
384 bool loader_alive = (loader == NULL) || is_alive->do_object_b(loader); 382 bool loader_alive = (loader == NULL) || is_alive->do_object_b(loader);
385 #endif // ASSERT 383 #endif // ASSERT