RFR: JDK-8213480: update internal ASM version to 7.0

forax at univ-mlv.fr forax at univ-mlv.fr
Fri Nov 9 22:11:53 UTC 2018


It's not the simplest solution but you can use a classloader or an agent to patch the bytecode of ASM with ASM at runtime :)

Rémi

----- Mail original -----
> De: "Igor Ignatyev" <igor.ignatyev at oracle.com>
> À: "Remi Forax" <forax at univ-mlv.fr>
> Cc: "Vicente Romero" <vicente.romero at oracle.com>, "Alan Bateman" <Alan.Bateman at oracle.com>, "hotspot-dev"
> <hotspot-dev at openjdk.java.net>, "core-libs-dev" <core-libs-dev at openjdk.java.net>
> Envoyé: Vendredi 9 Novembre 2018 22:12:48
> Objet: Re: RFR: JDK-8213480: update internal ASM version to 7.0

> Hi Remi,
> 
> 
> w/ SymbolTable::get being private method _and_ SymbolTable being final class, it
> doesn't sound like the easiest way ;) w/ that being said, I haven't looked at
> the latest version of ASM, so there might be ways to get that we need.
> 
> Thanks,
> -- Igor
> 
>> On Nov 9, 2018, at 11:33 AM, Remi Forax <forax at univ-mlv.fr> wrote:
>> 
>> Hi Igor,
>> sorry to have not answered to your mail :(
>> 
>> I believe that the easiest way to disable the caching of the entries of the
>> constant pool in ASM is to change SymbolTable.get() [1] to always return null.
>> 
>> regards,
>> Rémi
>> 
>> [1]
>> https://gitlab.ow2.org/asm/asm/blob/master/asm/src/main/java/org/objectweb/asm/SymbolTable.java#L393
>> 
>> ----- Mail original -----
>>> De: "Igor Ignatyev" <igor.ignatyev at oracle.com>
>>> À: "Vicente Romero" <vicente.romero at oracle.com>, "Alan Bateman"
>>> <Alan.Bateman at oracle.com>
>>> Cc: "hotspot-dev" <hotspot-dev at openjdk.java.net>, "core-libs-dev"
>>> <core-libs-dev at openjdk.java.net>
>>> Envoyé: Vendredi 9 Novembre 2018 17:25:49
>>> Objet: Re: RFR: JDK-8213480: update internal ASM version to 7.0
>> 
>>> Vicente, Alan,
>>> 
>>> back when we 1st bumped into this problem w/ ClassWriterExt (about 1y ago), it
>>> was my AI to discuss it w/ Remi. I sent him an email, didn't get a replay, and
>>> as it usually goes, had to switch to something else, completely forgot about
>>> that and didn't follow up.
>>> 
>>> Thanks,
>>> -- Igor
>>> 
>>>> On Nov 8, 2018, at 8:40 AM, Vicente Romero <vicente.romero at oracle.com> wrote:
>>>> 
>>>> 
>>>> 
>>>> On 11/8/18 8:14 AM, Alan Bateman wrote:
>>>>> On 07/11/2018 19:33, Igor Ignatyev wrote:
>>>>>> Hi Vicente,
>>>>>> 
>>>>>> I recall an (internal?) discussion about updating ASM somewhen in JDK 11TF, and
>>>>>> AFAIR it was decided not to update ASM b/c nothing in JDK needs that, has it
>>>>>> been changed? put somewhat differently, why are we doing this?
>>>>>> 
>>>>>> in any case, I don't like the changes in mlvm tests. I understand that
>>>>>> ClassWriter has been significantly changed in ASM 7.0, so ClassWriterExt can't
>>>>>> disable CP entries caching (at least not in the way it used to), but removing
>>>>>> setCache* calls from the tests changed them and in some cases made them invalid
>>>>>> as they don't test that they supposed to. therefore I'd prefer to leave all
>>>>>> calls setCache* as-is, change setCache* implementation to throw an exception
>>>>>> (similarly to the fix in JDK-8194826
>>>>>> <https://bugs.openjdk.java.net/browse/JDK-8194826>) and mark all tests which
>>>>>> throw this exception w/ '@ignore 8194951' jtreg tag.
>>>>>> 
>>>>>> 
>>>>> ClassWriterExt the MLVM tests have come in previous upgrades too. Has there been
>>>>> any discussion Remi or others on ASM to make it easier for the JDK to upgrade?
>>>> 
>>>> I'm not aware of any such discussions.
>>>> 
>>>>> 
>>>>> -Alan
>>>> 
> >>> Vicente


More information about the core-libs-dev mailing list