RFR: 8338544: Dedicated Array class descriptor implementation [v3]

Mandy Chung mchung at openjdk.org
Tue Oct 8 19:49:59 UTC 2024


On Tue, 8 Oct 2024 19:32:34 GMT, Chen Liang <liach at openjdk.org> wrote:

>> @cl4es discovered that Stack Map generation in ClassFile API uses `componentType` and `arrayType` for `aaload` `aastore` instructions, which are currently quite slow. We can split out array class descriptors from class or interfaces to support faster `arrayType` and `componentType` operations.
>> 
>> Tentative, as I currently have no way to measure the actual impact of this patch on the startup performance; however, this made the `ClassDesc` implementations much cleaner.
>
> Chen Liang has updated the pull request incrementally with one additional commit since the last revision:
> 
>   mlchung suggestions: elementType, improve utility methods

src/java.base/share/classes/java/lang/constant/ClassDesc.java line 281:

> 279:      *
> 280:      * @implSpec
> 281:      * <p>The implementations return the simple name

Suggestion:

     * <p>The implementation returns the simple name


I think this can be singular as it's not required to have more than 1 implementation class.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/20665#discussion_r1792419383


More information about the core-libs-dev mailing list