RFR: 8339112: Move JVM Klass flags out of AccessFlags [v3]

Dean Long dlong at openjdk.org
Fri Aug 30 20:26:53 UTC 2024


On Fri, 30 Aug 2024 14:00:44 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

>> Move JVM implementation access flags that are not specified by the classfile format into Klass so we can shrink AccessFlags to u2 in a future change.
>> 
>> Tested with tier1-7.
>> 
>> NOTE: there are arm, ppc and s390 changes to this that are just a guess.  Also, graal changes.
>
> Coleen Phillimore has updated the pull request incrementally with three additional commits since the last revision:
> 
>  - Fix jvmci code.
>  - Some C2 refactoring.
>  - Assembly corrections from Matias and Dean.

src/hotspot/share/opto/library_call.cpp line 3777:

> 3775:   Node* p = basic_plus_adr(kls, in_bytes(Klass::misc_flags_offset()));
> 3776:   Node* mods = make_load(nullptr, p, TypeInt::UBYTE, T_BOOLEAN, MemNode::unordered);
> 3777:   return generate_mods_flags_guard(mods, modifier_mask, modifier_bits, region);

Suggestion:

  return generate_mods_flags_guard(mods, modifier_mask, modifier_bits, region, Klass::misc_flags_offset(), TypeInt::UBYTE, T_BOOLEAN);

This looks much better, but can't you leave the basic_plus_adr and make_load in generate_mods_flags_guard, and pass in the needed specialization?

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/20719#discussion_r1739380935


More information about the serviceability-dev mailing list