RFR: 8334866: Improve Speed of ElfDecoder source search [v6]

Kerem Kat krk at openjdk.org
Wed Oct 29 11:56:27 UTC 2025


On Mon, 27 Oct 2025 09:27:04 GMT, Christian Hagedorn <chagedorn at openjdk.org> wrote:

>> Kerem Kat has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix comments, delete copy ctor
>
> src/hotspot/share/utilities/elfFile.cpp line 785:
> 
>> 783:           set_header._debug_info_offset
>> 784:         );
>> 785:         _cache._count++;
> 
> You do a lot of delegation to `_cache`. This suggests that it could be part of the cache class itself. How about having `add_entry()` with a `grow()` method there?

Thanks, created `add_entry`, `grow` and `sort`. This also eliminates the need to the forward declaration.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27337#discussion_r2472711027


More information about the hotspot-dev mailing list