RFR: 8342818: Implement CPU Time Profiling for JFR [v43]

Markus Grönlund mgronlun at openjdk.org
Mon Apr 28 21:16:01 UTC 2025


On Mon, 28 Apr 2025 10:39:32 GMT, Johannes Bechberger <jbechberger at openjdk.org> wrote:

>> src/hotspot/share/jfr/periodic/sampling/jfrCPUTimeThreadSampler.cpp line 556:
>> 
>>> 554:     stop_timer();
>>> 555:     Atomic::store(&_stop_signals, true);
>>> 556:     while (_active_signal_handlers > 0) {
>> 
>> This will cause the system to hang.
>> 
>>  The thread calling disenroll() is a JavaThread, which can get stuck in this while loop here, preventing the system from moving to a safepoint.
>
> I shouldn't get stuck here, as the signal handler is stopped and new signal handler invocations will not be incrementing _active_signal_handlers. Or do you I misunderstand your concerns?

Its apparently stuck because it hangs here in internal testing. Over 700000 active signal handlers?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/20752#discussion_r2064760182


More information about the hotspot-dev mailing list