mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-21 11:34:38 +02:00
8199781: Don't use naked == for comparing oops
Reviewed-by: coleenp, eosterlund, jrose
This commit is contained in:
parent
8b50176bdc
commit
b938ae51ce
36 changed files with 1484 additions and 1282 deletions
|
@ -249,7 +249,7 @@ ciObject* ciObjectFactory::get(oop key) {
|
|||
// into the cache.
|
||||
Handle keyHandle(Thread::current(), key);
|
||||
ciObject* new_object = create_new_object(keyHandle());
|
||||
assert(keyHandle() == new_object->get_oop(), "must be properly recorded");
|
||||
assert(oopDesc::equals(keyHandle(), new_object->get_oop()), "must be properly recorded");
|
||||
init_ident_of(new_object);
|
||||
assert(Universe::heap()->is_in_reserved(new_object->get_oop()), "must be");
|
||||
|
||||
|
@ -450,8 +450,8 @@ ciKlass* ciObjectFactory::get_unloaded_klass(ciKlass* accessing_klass,
|
|||
for (int i=0; i<_unloaded_klasses->length(); i++) {
|
||||
ciKlass* entry = _unloaded_klasses->at(i);
|
||||
if (entry->name()->equals(name) &&
|
||||
entry->loader() == loader &&
|
||||
entry->protection_domain() == domain) {
|
||||
oopDesc::equals(entry->loader(), loader) &&
|
||||
oopDesc::equals(entry->protection_domain(), domain)) {
|
||||
// We've found a match.
|
||||
return entry;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue