RFR: JDK-8318626: GetClassFields does not filter out ConstantPool.constantPoolOop field [v2]
Leonid Mesnik
lmesnik at openjdk.org
Wed Nov 29 00:05:06 UTC 2023
On Tue, 21 Nov 2023 02:58:47 GMT, Alex Menkov <amenkov at openjdk.org> wrote:
>> FilteredFieldStream is intended to filter out some fields which does not represent valid java objects.
>> Currently the only filtered field is "constantPoolOop" from jdk.internal.reflect.ConstantPool class.
>> The change fixes FilteredFieldStream implementation to handle cases when filtered fields is the last field of the class ("constantPoolOop" is the only field of jdk.internal.reflect.ConstantPool)
>>
>> Testing:
>> - new test added that compares results of GetClassFields JVMTI function (it uses FilteredFieldStream) with Class.getDeclaredFields();
>> - test/hotspot/jtreg/vmTestbase/nsk/jvmti/GetClassFields tests
>
> Alex Menkov has updated the pull request incrementally with one additional commit since the last revision:
>
> feedback
Marked as reviewed by lmesnik (Reviewer).
-------------
PR Review: https://git.openjdk.org/jdk/pull/16328#pullrequestreview-1754164029
More information about the serviceability-dev
mailing list