Run ruby benchmarks/lobsters/benchmark.rb with the patch
diff --git a/benchmarks/lobsters/benchmark.rb b/benchmarks/lobsters/benchmark.rb index 240c50c..6cdd0ac 100644 --- a/benchmarks/lobsters/benchmark.rb +++ b/benchmarks/lobsters/benchmark.rb @@ -7,6 +7,8 @@ Dir.chdir __dir__ use_gemfile require_relative 'config/environment' +printf "allocated_after_load=%d\n", GC.stat(:total_allocated_objects) +exit require_relative "route_generator" # For an in-mem DB, we need to load all data on every boot
[Bug #20695] Do not create needless string object in parser
set_parser_s_valuedoes nothing in parser therefore no need tocreate string object in parser
set_yylval_node.Object allocation¶
Run
ruby benchmarks/lobsters/benchmark.rbwith the patchBefore¶
After¶
Ruby 3.3.0 for reference¶