Integrated: 8350854: Include thread counts in safepoint logging

Xiaolong Peng xpeng at openjdk.org
Wed Mar 5 16:39:00 UTC 2025


On Fri, 28 Feb 2025 09:16:19 GMT, Xiaolong Peng <xpeng at openjdk.org> wrote:

> The PR is to add thread counts in safepoint logging. In recent work, we notice the number of Java thread may affects time to reach/leave safepoint hardly in some cases, but safepoint logging doesn't have thread counts, thread counts are printed only with 'safepoint+stats' log. 
> 
> Given in many cases, we only have `safepoint` log enabled, not `safepoint+stats`, it make sense to add thread count to 'safepoint' logging. 
> 
> Here is example log output with the change:
> 
> [15.240s][info][safepoint      ] Safepoint "ShenandoahFinalMarkStartEvac", Time since last: 3527459 ns, Reaching safepoint: 78666 ns, At safepoint: 821625 ns, Leaving safepoint: 1472167 ns, Total: 2372458 ns, Threads: 3 runnable, 1038 total
> 
> 
> 
> ### Test
> - [x] Tire1
> - [x] Tire2

This pull request has now been integrated.

Changeset: 61d9ab97
Author:    Xiaolong Peng <xpeng at openjdk.org>
Committer: Aleksey Shipilev <shade at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/61d9ab9717783e5bb0faa555f794499d0e5b3fdb
Stats:     5 lines in 1 file changed: 3 ins; 0 del; 2 mod

8350854: Include thread counts in safepoint logging

Reviewed-by: shade, dholmes

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

PR: https://git.openjdk.org/jdk/pull/23838


More information about the hotspot-runtime-dev mailing list