RFR: 8307488: Incorrect weight of the first ObjectAllocationSample JFR event [v2]

Markus Grönlund mgronlun at openjdk.org
Tue May 30 10:34:09 UTC 2023


On Tue, 30 May 2023 09:34:01 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

>> Markus Grönlund has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   variable rename
>
> src/hotspot/share/jfr/recorder/service/jfrRecorderService.cpp line 146:
> 
>> 144:   iterate(jit, coas);
>> 145:   JfrNonJavaThreadIterator njit;
>> 146:   iterate(njit, coas);
> 
> Apologies for the post-integration review, but I have a question/suggestion. This code retains the JavaThread iterator while NonJavaThreadIterator is running, which feels unnecessary. Also, if we have thousands of threads, walking these threads and doing the unconditional `clear_last_allocated_bytes` there seems redundant and heavy-weight if the relevant JFR event is off.

At this point, no recording is running, and no event settings are applied. No state exists to know if the event was enabled when the previous, last recording stopped.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/14158#discussion_r1210073272


More information about the hotspot-jfr-dev mailing list