On Fri, 23 May 2025 21:20:39 GMT, Johannes Bechberger <jbechber...@openjdk.org> wrote:
>> This is the code for the [JEP 509: CPU Time based profiling for >> JFR](https://openjdk.org/jeps/509). >> >> Currently tested using [this test >> suite](https://github.com/parttimenerd/basic-profiler-tests). This runs >> profiles the [Renaissance](https://renaissance.dev/) benchmark with >> - ... different heap sizes >> - ... different GCs >> - ... different samplers (the standard JFR and the new CPU Time Sampler and >> both) >> - ... different JFR recording durations >> - ... different chunk-sizes > > Johannes Bechberger has updated the pull request incrementally with one > additional commit since the last revision: > > Fix compilation src/hotspot/share/jfr/periodic/sampling/jfrCPUTimeThreadSampler.cpp line 590: > 588: // so samples might be skipped and we have to compute the actual period > 589: int64_t period = get_sampling_period() * (info->si_overrun + 1); > 590: request._cpu_time_period = Ticks(period / 1000000000.0 * > JfrTime::frequency()) - Ticks(0); Are you treating JfrTime::frequency() as nanos here? JfrTime::frequency() can be in ticks, hence not a valid conversion. src/hotspot/share/jfr/periodic/sampling/jfrCPUTimeThreadSampler.cpp line 630: > 628: > 629: bool JfrCPUTimeThreadSampler::create_timer_for_thread(JavaThread* > thread, timer_t& timerid) { > 630: if (thread->osthread() == nullptr || thread->osthread()->thread_id() > == 0){ When is this possible? ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/25302#discussion_r2106229890 PR Review Comment: https://git.openjdk.org/jdk/pull/25302#discussion_r2106230710