Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

L/Q again, step two #414

Closed
wants to merge 7 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -111,30 +111,21 @@ ciArrayKlass* ciArrayKlass::make(ciType* element_type) {
}

ciArrayKlass* ciArrayKlass::make(ciKlass* klass, bool null_free) {
if (null_free) {
if (klass->is_loaded()) {
bool is_array_flattened = false;
GUARDED_VM_ENTRY(
EXCEPTION_CONTEXT;
Klass* ak = InlineKlass::cast(klass->get_Klass())->null_free_inline_array_klass(THREAD);
if (HAS_PENDING_EXCEPTION) {
CLEAR_PENDING_EXCEPTION;
} else {
if (ak != NULL && ak->is_flatArray_klass()) {
is_array_flattened = true;
}
}
)
if (is_array_flattened) {
return ciFlatArrayKlass::make(klass);
if (null_free && klass->is_loaded()) {
GUARDED_VM_ENTRY(
EXCEPTION_CONTEXT;
Klass* ak = InlineKlass::cast(klass->get_Klass())->null_free_inline_array_klass(THREAD);
if (HAS_PENDING_EXCEPTION) {
CLEAR_PENDING_EXCEPTION;
} else {
return ciObjArrayKlass::make(klass, true);
if (ak != NULL && ak->is_flatArray_klass()) {
Copy link
Member

@TobiHartmann TobiHartmann May 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

else and if can be merged

Copy link
Collaborator Author

@fparain fparain May 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code updated.

return ciFlatArrayKlass::make(klass);
}
}
} else {
return ciEnv::unloaded_ciobjarrayklass();
}
)
return ciObjArrayKlass::make(klass, true);
} else {
return ciObjArrayKlass::make(klass);
return ciObjArrayKlass::make(klass, null_free);
}
}