hotspot/src/share/vm/classfile/systemDictionary.cpp
changeset 25490 59f226da8d81
parent 25066 57d8cb758cf8
child 25491 70fb742e40aa
equal deleted inserted replaced
25489:feb54edc509d 25490:59f226da8d81
  1610 //
  1610 //
  1611 // The second phase removes (unloads) unreachable classes from the
  1611 // The second phase removes (unloads) unreachable classes from the
  1612 // system dictionary and follows the remaining classes' contents.
  1612 // system dictionary and follows the remaining classes' contents.
  1613 
  1613 
  1614 void SystemDictionary::always_strong_oops_do(OopClosure* blk) {
  1614 void SystemDictionary::always_strong_oops_do(OopClosure* blk) {
  1615   blk->do_oop(&_java_system_loader);
  1615   roots_oops_do(blk, NULL);
  1616   blk->do_oop(&_system_loader_lock_obj);
       
  1617 
       
  1618   dictionary()->always_strong_oops_do(blk);
       
  1619 
       
  1620   // Visit extra methods
       
  1621   invoke_method_table()->oops_do(blk);
       
  1622 }
  1616 }
  1623 
  1617 
  1624 void SystemDictionary::always_strong_classes_do(KlassClosure* closure) {
  1618 void SystemDictionary::always_strong_classes_do(KlassClosure* closure) {
  1625   // Follow all system classes and temporary placeholders in dictionary
  1619   // Follow all system classes and temporary placeholders in dictionary
  1626   dictionary()->always_strong_classes_do(closure);
  1620   dictionary()->always_strong_classes_do(closure);
  1681 #ifdef ASSERT
  1675 #ifdef ASSERT
  1682   VerifySDReachableAndLiveClosure cl(is_alive);
  1676   VerifySDReachableAndLiveClosure cl(is_alive);
  1683   dictionary()->oops_do(&cl);
  1677   dictionary()->oops_do(&cl);
  1684 #endif
  1678 #endif
  1685   return unloading_occurred;
  1679   return unloading_occurred;
       
  1680 }
       
  1681 
       
  1682 void SystemDictionary::roots_oops_do(OopClosure* strong, OopClosure* weak) {
       
  1683   strong->do_oop(&_java_system_loader);
       
  1684   strong->do_oop(&_system_loader_lock_obj);
       
  1685 
       
  1686   // Adjust dictionary
       
  1687   dictionary()->roots_oops_do(strong, weak);
       
  1688 
       
  1689   // Visit extra methods
       
  1690   invoke_method_table()->oops_do(strong);
  1686 }
  1691 }
  1687 
  1692 
  1688 void SystemDictionary::oops_do(OopClosure* f) {
  1693 void SystemDictionary::oops_do(OopClosure* f) {
  1689   f->do_oop(&_java_system_loader);
  1694   f->do_oop(&_java_system_loader);
  1690   f->do_oop(&_system_loader_lock_obj);
  1695   f->do_oop(&_system_loader_lock_obj);