RFR: 8306460: Clear JVM_ACC_QUEUED flag on methods when dumping dynamic CDS archive [v2]

Coleen Phillimore coleenp at openjdk.org
Mon May 15 17:21:54 UTC 2023


On Sat, 6 May 2023 14:02:17 GMT, Ashutosh Mehra <duke at openjdk.org> wrote:

>> This patch clears the method's "queued_for_compilation" flag when dumping the method in CDS archive. Also added an assert in `Method::restore_unshareable_info()` that the method being restored should not have that flag set.
>
> Ashutosh Mehra has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains three additional commits since the last revision:
> 
>  - Remove unshareable flags in Method and InstanceKlass
>    
>    Signed-off-by: Ashutosh Mehra <asmehra at redhat.com>
>  - Merge branch 'master' of github.com:openjdk/jdk into JDK-8306460
>  - 8306460: Clear JVM_ACC_QUEUED flag on methods when dumping dynamic CDS archive
>    
>    Signed-off-by: Ashutosh Mehra <asmehra at redhat.com>

src/hotspot/share/oops/instanceKlass.cpp line 2602:

> 2600:   // clear all the flags/stats that shouldn't be in the archived version
> 2601: #if INCLUDE_JVMTI
> 2602:   set_is_being_redefined(false);

I think this should assert !is_scratch_class() and clear (?) is_redefined() also.  It's unfortunate that we can't just clear all the status flags here and in Method.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/13652#discussion_r1194133054


More information about the hotspot-dev mailing list