Add stat force_incremental_marking_finish_count

This commit adds key force_incremental_marking_finish_count to
GC.stat_heap. This statistic returns the number of times the size pool
has forced incremental marking to finish due to running out of slots.
This commit is contained in:
Peter Zhu 2023-08-14 11:24:50 -04:00
parent 8c5b9ebf71
commit 0f94e65359
3 changed files with 9 additions and 0 deletions

3
gc.rb
View file

@ -244,6 +244,9 @@ module GC
# [force_major_gc_count]
# The number of times major garbage collection cycles this heap has forced
# to start due to running out of free slots.
# [force_incremental_marking_finish_count]
# The number of times this heap has forced incremental marking to complete
# due to running out of pooled slots.
#
def self.stat_heap heap_name = nil, hash_or_key = nil
Primitive.gc_stat_heap heap_name, hash_or_key