Integrated: 8372412: Increase buffer size for ring-buffer events in CollectedHeap

Joel Sikström jsikstro at openjdk.org
Tue Nov 25 14:57:54 UTC 2025


On Mon, 24 Nov 2025 14:09:59 GMT, Joel Sikström <jsikstro at openjdk.org> wrote:

> Hello,
> 
> The buffer size we changed to when separating GC and Metaspace printing code is too small for Parallel and Serial (and maybe also for long-running programs in general). I suggest we bump the buffer-size to 1024 bytes. This also leaves room for more lengthy prints, which ZGC might have if running on a machine with many NUMA nodes.
> 
> The default number of events stored in each ring-buffer is 20, controlled via the diagnostic flag `LogEventsBufferEntries`. In it's default setting, the total memory usage of each ring-buffer (Metaspace and Heap) will increase from (512 bytes * 20) 10KB to (1024 * 20) 20KB.
> 
> For completeness, the content of the ring-buffers are only printed in hs_err files, using the `-XX:+PrintVMInfoAtExit` (diagnostic flag) or using `jcmd VM.info`
> 
> Testing:
> * Local testing with `java -XX:+UseParalellGC/UseSerialGC -XX:+PrintVMInfoAtExit ...` to see that the message is not cut-off any longer.

This pull request has now been integrated.

Changeset: 81ea1442
Author:    Joel Sikström <jsikstro at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/81ea1442a86795dafbf96c875fbecc65210804be
Stats:     1 line in 1 file changed: 0 ins; 0 del; 1 mod

8372412: Increase buffer size for ring-buffer events in CollectedHeap

Reviewed-by: stefank, tschatzl

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

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


More information about the hotspot-gc-dev mailing list