On Fri, 5 Jun 2026 12:39:42 GMT, Johan Sjölen <[email protected]> wrote:

>> Hi,
>> 
>> - Switch the statistics gathering code to be the same as for the string 
>> table (both being based on the statistics gathering in CHT)
>> - Remove the old `statistics_get` function in CHT, as it's now unused
>> - Some minor changes to improve clarity in `VM_DumpHashtable` (`DumpSysDict` 
>> was actually implemented)
>> 
>> The old `Dictionary` statistics fetching function seemed very broken to me 
>> as it would return the statistics to another table if the table's 
>> `resize_lock` was already held by another thread. Just using the same 
>> mechanism seems reasonable.
>> 
>> Testing: GHA and manually ran `jcmd $PID VM.systemdictionary`
>> 
>> ---------
>> - [X] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Johan Sjölen has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Print failure and return

At one point, I didn't want there to be the same code in StringTable, 
SymbolTable and now in Dictionary to print statistics.   Maybe they can be 
consolidated someday. The statistic_get function looks really wrong, so this is 
a good cleanup!

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

Marked as reviewed by coleenp (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/31398#pullrequestreview-4438919461

Reply via email to