< prev index next >
src/share/vm/classfile/dictionary.cpp
Print this page
rev 8961 : [mq]: diff-shenandoah.patch
*** 78,94 ****
}
bool DictionaryEntry::contains_protection_domain(oop protection_domain) const {
#ifdef ASSERT
! if (protection_domain == InstanceKlass::cast(klass())->protection_domain()) {
// Ensure this doesn't show up in the pd_set (invariant)
bool in_pd_set = false;
for (ProtectionDomainEntry* current = _pd_set;
current != NULL;
current = current->next()) {
! if (current->protection_domain() == protection_domain) {
in_pd_set = true;
break;
}
}
if (in_pd_set) {
--- 78,95 ----
}
bool DictionaryEntry::contains_protection_domain(oop protection_domain) const {
#ifdef ASSERT
! protection_domain = oopDesc::bs()->resolve_and_maybe_copy_oop(protection_domain);
! if (protection_domain == oopDesc::bs()->resolve_and_maybe_copy_oop(InstanceKlass::cast(klass())->protection_domain())) {
// Ensure this doesn't show up in the pd_set (invariant)
bool in_pd_set = false;
for (ProtectionDomainEntry* current = _pd_set;
current != NULL;
current = current->next()) {
! if (oopDesc::bs()->resolve_and_maybe_copy_oop(current->protection_domain()) == protection_domain) {
in_pd_set = true;
break;
}
}
if (in_pd_set) {
*** 96,114 ****
"in its sys. dict. PD set");
}
}
#endif /* ASSERT */
! if (protection_domain == InstanceKlass::cast(klass())->protection_domain()) {
// Succeeds trivially
return true;
}
for (ProtectionDomainEntry* current = _pd_set;
current != NULL;
current = current->next()) {
! if (current->protection_domain() == protection_domain) return true;
}
return false;
}
--- 97,115 ----
"in its sys. dict. PD set");
}
}
#endif /* ASSERT */
! if (protection_domain == oopDesc::bs()->resolve_and_maybe_copy_oop(InstanceKlass::cast(klass())->protection_domain())) {
// Succeeds trivially
return true;
}
for (ProtectionDomainEntry* current = _pd_set;
current != NULL;
current = current->next()) {
! if (oopDesc::bs()->resolve_and_maybe_copy_oop(current->protection_domain()) == protection_domain) return true;
}
return false;
}
< prev index next >