[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-serviceability-dev
Subject:    Integrated: 8282241: Invalid generic signature for redefined classes
From:       Alex Menkov <amenkov () openjdk ! java ! net>
Date:       2022-03-23 18:35:34
Message-ID: WTrmydhqMMYVMbTS6N0927-ldDPfp8O8rW8lhfHR8z0=.14635876-1b2d-4481-b40f-a83d8da26571 () github ! com
[Download RAW message or body]

On Thu, 3 Mar 2022 15:07:05 GMT, Alex Menkov <amenkov@openjdk.org> wrote:

> JDK-8238048 (fixed in jdk15) moved major_version, minor_version, \
> generic_signature_index and source_file_name_index from InstanceKlass to \
> ConstantPool. We still have some incorrect code in CP merge during class \
> redefinition. 
> rewrite_cp_refs(scratch_class) updates generic_signature_index and \
> source_file_name_index in the scratch_cp, so we need to copy the attributes \
> (merge_cp->copy_fields(scratch_cp())) after rewrite_cp_refs. 
> In redefine_single_class we don't need to copy source_file_name_index because it's \
> a CP property and we swap CPs. So this copying actually sets the value from old \
> class. 
> tested:
> - test/jdk/java/lang/instrument
> - test/hotspot/jtreg/serviceability/jvmti/RedefineClasses
> - test/hotspot/jtreg/vmTestbase/nsk/jvmti/RedefineClasses
> - test/hotspot/jtreg/vmTestbase/nsk/jvmti/RetransformClasses

This pull request has now been integrated.

Changeset: f0177395
Author:    Alex Menkov <amenkov@openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/f01773956fbc092b00c18392735a020ca05257ed
                
Stats:     212 lines in 2 files changed: 202 ins; 7 del; 3 mod

8282241: Invalid generic signature for redefined classes

Reviewed-by: coleenp, sspitsyn

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

PR: https://git.openjdk.java.net/jdk/pull/7676


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic