ee4013b90f (master): Count global GC cycles per Ractor in GC.stat

0 views
Skip to first unread message

Matt Valentine-House

unread,
Oct 5, 2026, 2:08:45 PM (yesterday) Oct 5
to ruby...@g.ruby-lang.org
Matt Valentine-House 2026-10-01 09:00:02 +0000 (Thu, 01 Oct 2026)

New Revision: ee4013b90f

https://github.com/ruby/ruby/commit/ee4013b90f

Log:
Count global GC cycles per Ractor in GC.stat

GC.stat(:global_gc_count) now reports the stop-the-world global cycles
the current Ractor started, instead of mirroring the process-wide count,
so the values can be summed across Ractors. GC.stat(:global_gc_count,
scope: :global) gives the process total, including Ractors that have
since exited.

A global cycle no longer counts as a major GC on the Ractor that started
it, so count == minor_gc_count + major_gc_count + global_gc_count
Reply all
Reply to author
Forward
0 new messages