On Fri, 2 Feb 2024 02:49:13 GMT, Alex Menkov <amen...@openjdk.org> wrote:

>> FilteredFieldStream used by heap walking functions to iterate through 
>> klass/superclasses/interfaces fields are known to have poor performance (see 
>> [JDK-8317692](https://bugs.openjdk.org/browse/JDK-8317692) for details).
>> Heap walking API implementation is the last user of the klasses.
>> The fix reworks iteration through klass/superclasses/interfaces fields and 
>> drops FilteredFieldStream-related code.
>> Additionally removed/updated includes of reflectionUtils.hpp.
>> 
>> Testing:
>>   - tier1..4;
>>   - test/hotspot/jtreg/vmTestbase/nsk/jvmti (contains tests for different 
>> heap walking functions);
>>   - new test from #17580 (now the test runs several times faster).
>
> Alex Menkov has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   jcheck

Looks good. There is one minor comment though.

src/hotspot/share/prims/jvmtiTagMap.cpp line 499:

> 497:     }
> 498:     // update total_field_number for superclass
> 499:     total_field_number = start_index;

Nit: The local variable name `total_field_number` is a little bit confusing 
because it is instantly decreased here (see also the line 490). I'm not sure 
what name to suggest though. Maybe the comment at line 498 needs an update to 
say this number is decreased here.

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

Marked as reviewed by sspitsyn (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/17661#pullrequestreview-1858613748
PR Review Comment: https://git.openjdk.org/jdk/pull/17661#discussion_r1475699883

Reply via email to