src/share/vm/oops/instanceKlass.cpp

Print this page




2159     assert_is_in)
2160   return size;
2161 }
2162 
2163 #if INCLUDE_ALL_GCS
2164 void InstanceKlass::oop_push_contents(PSPromotionManager* pm, oop obj) {
2165   InstanceKlass_OOP_MAP_REVERSE_ITERATE( \
2166     obj, \
2167     if (PSScavenge::should_scavenge(p)) { \
2168       pm->claim_or_forward_depth(p); \
2169     }, \
2170     assert_nothing )
2171 }
2172 
2173 int InstanceKlass::oop_update_pointers(ParCompactionManager* cm, oop obj) {
2174   int size = size_helper();
2175   InstanceKlass_OOP_MAP_ITERATE( \
2176     obj, \
2177     PSParallelCompact::adjust_pointer(p), \
2178     assert_is_in)
2179   obj->update_header(cm);
2180   return size;
2181 }
2182 
2183 #endif // INCLUDE_ALL_GCS
2184 
2185 void InstanceKlass::clean_implementors_list(BoolObjectClosure* is_alive) {
2186   assert(is_loader_alive(is_alive), "this klass should be live");
2187   if (is_interface()) {
2188     if (ClassUnloading) {
2189       Klass* impl = implementor();
2190       if (impl != NULL) {
2191         if (!impl->is_loader_alive(is_alive)) {
2192           // remove this guy
2193           Klass** klass = adr_implementor();
2194           assert(klass != NULL, "null klass");
2195           if (klass != NULL) {
2196             *klass = NULL;
2197           }
2198         }
2199       }




2159     assert_is_in)
2160   return size;
2161 }
2162 
2163 #if INCLUDE_ALL_GCS
2164 void InstanceKlass::oop_push_contents(PSPromotionManager* pm, oop obj) {
2165   InstanceKlass_OOP_MAP_REVERSE_ITERATE( \
2166     obj, \
2167     if (PSScavenge::should_scavenge(p)) { \
2168       pm->claim_or_forward_depth(p); \
2169     }, \
2170     assert_nothing )
2171 }
2172 
2173 int InstanceKlass::oop_update_pointers(ParCompactionManager* cm, oop obj) {
2174   int size = size_helper();
2175   InstanceKlass_OOP_MAP_ITERATE( \
2176     obj, \
2177     PSParallelCompact::adjust_pointer(p), \
2178     assert_is_in)

2179   return size;
2180 }
2181 
2182 #endif // INCLUDE_ALL_GCS
2183 
2184 void InstanceKlass::clean_implementors_list(BoolObjectClosure* is_alive) {
2185   assert(is_loader_alive(is_alive), "this klass should be live");
2186   if (is_interface()) {
2187     if (ClassUnloading) {
2188       Klass* impl = implementor();
2189       if (impl != NULL) {
2190         if (!impl->is_loader_alive(is_alive)) {
2191           // remove this guy
2192           Klass** klass = adr_implementor();
2193           assert(klass != NULL, "null klass");
2194           if (klass != NULL) {
2195             *klass = NULL;
2196           }
2197         }
2198       }