RFR 8200261: Regression with JVM anonymous class

Lois Foltan lois.foltan at oracle.com
Wed Apr 4 20:50:17 UTC 2018

On 4/4/2018 1:29 PM, harold seigel wrote:

> Hi,
> Please review this JDK-11 fix for JDK-8200261.  When the JVM default 
> method processing creates an expanded constant pool, to add overpass 
> methods, for an anonymous class, it needs to ensure that the (eagerly) 
> resolved anonymous class get copied into the new constant pool's 
> klasses array.  Otherwise, the anonymous class will be unable to find 
> its own fields and methods.  This is only needed for anonymous classes 
> because other classes get resolved after default method processing.
> Open Webrev: 
> http://cr.openjdk.java.net/~hseigel/bug_8200261/webrev/index.html
> JBS Bug:  https://bugs.openjdk.java.net/browse/JDK-8200261

Hi Harold,
Fix looks good.  Two minor clarification questions about the setting & 
retrieving of the index, since this is intended only for anonymous classes:

- line #5427 - did you consider calling set_this_class_index from within 
the "if (is_anonymous())" if statement at line #5429
- line #521 - should there be asserts in these setter/getter methods to 
check for an anonymous class?


> This fix was tested with Mach5 tiers 1 and 2 tests and builds on all 
> Mach5 platforms, with tiers 3-5 tests on Linux-x64, with JCK-10 Lang 
> and VM tests, and with additional JDK JTReg tests.
> Thanks, Harold

More information about the hotspot-runtime-dev mailing list