src/share/vm/oops/methodData.cpp

changeset 6105
6e1826d5c23e
parent 5987
5ccbab1c69f3
child 6377
b8413a9cbb84
child 6485
da862781b584
equal deleted inserted replaced
6104:924c32982a12 6105:6e1826d5c23e
273 _ret.post_initialize(); 273 _ret.post_initialize();
274 } 274 }
275 } 275 }
276 276
277 bool TypeEntries::is_loader_alive(BoolObjectClosure* is_alive_cl, intptr_t p) { 277 bool TypeEntries::is_loader_alive(BoolObjectClosure* is_alive_cl, intptr_t p) {
278 return !is_type_none(p) && 278 Klass* k = (Klass*)klass_part(p);
279 !((Klass*)klass_part(p))->is_loader_alive(is_alive_cl); 279 return k != NULL && k->is_loader_alive(is_alive_cl);
280 } 280 }
281 281
282 void TypeStackSlotEntries::clean_weak_klass_links(BoolObjectClosure* is_alive_cl) { 282 void TypeStackSlotEntries::clean_weak_klass_links(BoolObjectClosure* is_alive_cl) {
283 for (int i = 0; i < _number_of_entries; i++) { 283 for (int i = 0; i < _number_of_entries; i++) {
284 intptr_t p = type(i); 284 intptr_t p = type(i);
285 if (is_loader_alive(is_alive_cl, p)) { 285 if (!is_loader_alive(is_alive_cl, p)) {
286 set_type(i, type_none()); 286 set_type(i, with_status((Klass*)NULL, p));
287 } 287 }
288 } 288 }
289 } 289 }
290 290
291 void ReturnTypeEntry::clean_weak_klass_links(BoolObjectClosure* is_alive_cl) { 291 void ReturnTypeEntry::clean_weak_klass_links(BoolObjectClosure* is_alive_cl) {
292 intptr_t p = type(); 292 intptr_t p = type();
293 if (is_loader_alive(is_alive_cl, p)) { 293 if (!is_loader_alive(is_alive_cl, p)) {
294 set_type(type_none()); 294 set_type(with_status((Klass*)NULL, p));
295 } 295 }
296 } 296 }
297 297
298 bool TypeEntriesAtCall::return_profiling_enabled() { 298 bool TypeEntriesAtCall::return_profiling_enabled() {
299 return MethodData::profile_return(); 299 return MethodData::profile_return();

mercurial