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

8275775: VM.metaspace prints flag 'f' for classes that have non-trivial finalize() #6075

Closed
wants to merge 5 commits into from
Closed
Changes from 3 commits
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
@@ -147,7 +147,7 @@ void PrintCLDMetaspaceInfoClosure::do_cld(ClassLoaderData* cld) {
streamIndentor sti(_out, 6);
_out->cr_indent();
_out->print("Loaded classes");
_out->print("('s' = shared, 'f' = override_finalize)");
_out->print("('s' = shared, 'f' = has_nontrivial_finalize)");
_out->print(":");
PrintMetaspaceInfoKlassClosure pkic(_out, true);
cld->classes_do(&pkic);
@@ -43,8 +43,8 @@ void PrintMetaspaceInfoKlassClosure::do_klass(Klass* k) {

// Print a 's' for shared classes
_out->put(k->is_shared() ? 's' : ' ');
// Print 's' for classes that overrided finalize() method
_out->put(k->has_finalizer() ?'f' : ' ');
// Print a 'f' for classes that having a non-trivial finalize() method
Copy link
Member

@dholmes-ora dholmes-ora Oct 26, 2021

Choose a reason for hiding this comment

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

s/a/an/ (as 'f' is pronounced eff it gets treated as a vowel)
s/having/have/

Copy link
Member Author

@kelthuzadx kelthuzadx Oct 27, 2021

Choose a reason for hiding this comment

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

Oops.. Good catch!

_out->put(k->has_finalizer() ? 'f' : ' ');

ResourceMark rm;
_out->print(" %s (" INTPTR_FORMAT ")", k->external_name(), p2i(k));
Copy link
Member

@dholmes-ora dholmes-ora Oct 25, 2021

Choose a reason for hiding this comment

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

Why do we need the address printed?

Copy link
Member Author

@kelthuzadx kelthuzadx Oct 26, 2021

Choose a reason for hiding this comment

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

I guess this would facilitate further debugging. I will remove them if you think they are not necessary.

Copy link
Member

@tstuefe tstuefe Oct 27, 2021

Choose a reason for hiding this comment

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

Please remove it. Its not needed in this context.