RFR: 8358619: Fix interval recomputation in CPU Time Profiler
Jaroslav Bachorik
jbachorik at openjdk.org
Wed Jun 18 11:50:29 UTC 2025
On Thu, 12 Jun 2025 09:27:30 GMT, Johannes Bechberger <jbechberger at openjdk.org> wrote:
> Fixes the recomputation issue by passing either the rate or the period directly to the sampler (instead of just the rate value with the period value converted into a rate). This prevents issues when the number of cores changes during the JFR recording.
src/hotspot/share/jfr/periodic/sampling/jfrCPUTimeThreadSampler.cpp line 171:
> 169: double _rate;
> 170: u8 _period_nanos;
> 171: bool _is_rate;
Can this be turned into `union`?
Only one of `_rate` or `_period_nanos` will ever be set at a time.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/25775#discussion_r2154393526
More information about the hotspot-jfr-dev
mailing list