8217325: Enable inlining of java_lang_Class::oop_size_raw

Reviewed-by: shade, coleenp, rehn, stefank
This commit is contained in:
Claes Redestad 2019-01-18 08:00:05 +01:00
parent ef3336ec27
commit e86a7eea79
3 changed files with 8 additions and 7 deletions

View file

@ -190,6 +190,13 @@ inline bool java_lang_Class::is_primitive(oop java_class) {
return is_primitive;
}
inline int java_lang_Class::oop_size_raw(oop java_class) {
assert(_oop_size_offset != 0, "must be set");
int size = java_class->int_field_raw(_oop_size_offset);
assert(size > 0, "Oop size must be greater than zero, not %d", size);
return size;
}
inline bool java_lang_invoke_DirectMethodHandle::is_instance(oop obj) {
return obj != NULL && is_subclass(obj->klass());
}