From 3ab34551450c7a3a3e1ae0b24bf6b78d26129dfa Mon Sep 17 00:00:00 2001 From: Jean Boussier Date: Fri, 3 Feb 2023 09:46:14 +0100 Subject: Add RUBY_GC_HEAP_INIT_SIZE_%d_SLOTS to pre-init pools granularly The old RUBY_GC_HEAP_INIT_SLOTS isn't really usable anymore as it initalize all the pools by the same factor, but it's unlikely that pools will need similar sizes. In production our 40B pool is 5 to 6 times bigger than our 80B pool. --- man/ruby.1 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'man') diff --git a/man/ruby.1 b/man/ruby.1 index 86ad73c2ab..779167ac3e 100644 --- a/man/ruby.1 +++ b/man/ruby.1 @@ -550,7 +550,12 @@ There are currently 4 possible areas where the GC may be tuned by the following 11 environment variables: .Bl -hang -compact -width "RUBY_GC_OLDMALLOC_LIMIT_GROWTH_FACTOR" .It Ev RUBY_GC_HEAP_INIT_SLOTS -Initial allocation slots. Introduced in Ruby 2.1, default: 10000. +Initial allocation slots. Applies to all slot sizes. Introduced in Ruby 2.1, default: 10000. +.Pp +.It Ev RUBY_GC_HEAP_INIT_SIZE_%d_SLOTS +Initial allocation of slots in a specific size pool. +The available size pools can be found in `GC.stat_heap`. +Introduced in Ruby 3.3. .Pp .It Ev RUBY_GC_HEAP_FREE_SLOTS Prepare at least this amount of slots after GC. -- cgit v1.2.1