YJIT Benchmarks

Details for Benchmarks at 2025-05-29 03:53:09 UTC

YJIT metrics from the yjit-bench suite using Ruby fa85d23ff4.

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 88.4% faster than CRuby 3.5.0dev
  • 5.5% faster than YJIT 3.3.6
On railsbench it is
  • 102.9% faster than CRuby 3.5.0dev
  • 6.7% faster than YJIT 3.3.6
x86_64 runtime: 4 hours, 26 minutes
aarch64 runtime: 3 hours, 44 minutes

Performance on Headline Benchmarks

Speed of each Ruby implementation relative to the baseline CRuby measurement. Higher is better.

Memory Usage on Headline Benchmarks

Memory usage of each Ruby implementation relative to the baseline CRuby measurement. Lower is better.

Performance on Other Benchmarks

Speed of each Ruby implementation relative to the baseline CRuby measurement. Higher is better.

Memory Usage on Other Benchmarks

Memory usage of each Ruby implementation relative to the baseline CRuby measurement. Lower is better.

Performance on MicroBenchmarks

Speed of each Ruby implementation relative to the baseline CRuby measurement. Higher is better.

Memory Usage on MicroBenchmarks

Memory usage of each Ruby implementation relative to the baseline CRuby measurement. Lower is better.

Want Raw Graphs and CSV?

Benchmarks Speed Details

Benchmark Memory Usage Details

Number of Iterations and Warmups Tested

bench CRuby 3.3.6 warmups CRuby 3.3.6 iters CRuby 3.5.0dev warmups CRuby 3.5.0dev iters YJIT 3.3.6 warmups YJIT 3.3.6 iters YJIT 3.5.0dev warmups YJIT 3.5.0dev iters
activerecord 5 82 5 84 50 155 50 158
chunky-png 5 31 5 32 50 14 50 24
erubi-rails 5 16 5 15 50 10 50 10
hexapdf 5 10 5 10 50 10 50 10
liquid-c 5 405 5 421 50 572 50 620
liquid-compile 5 407 5 459 50 540 50 697
liquid-render 5 170 5 170 50 403 50 441
lobsters 5 20 5 19 50 10 50 10
mail 5 194 5 177 50 236 50 200
psych-load 5 10 5 10 50 10 50 10
railsbench 5 10 5 10 50 10 50 10
rubocop 5 157 5 156 50 251 50 262
ruby-lsp 5 155 5 156 50 257 50 264
sequel 5 427 5 425 50 598 50 589
binarytrees 5 84 5 83 50 146 50 133
blurhash 5 82 5 88 50 127 50 145
erubi 5 125 5 129 50 98 50 140
etanni 5 90 5 98 50 53 50 67
fannkuchredux 5 52 5 57 50 97 50 109
fluentd 5 63 5 64 50 26 50 28
graphql 5 85 5 86 50 58 50 54
graphql-native 5 40 5 56 50 10 50 18
lee 5 22 5 25 50 10 50 10
matmul 5 51 5 52 50 88 50 97
nbody 5 249 5 259 50 584 50 694
nqueens 5 120 5 127 50 75 50 556
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 171 5 185 50 621 50 726
protoboeuf-encode 5 177 5 204 50 328 50 773
rack 5 576 5 630 50 957 50 1063
ruby-json 5 84 5 83 50 49 50 49
rubyboy 5 10 5 10 50 10 50 10
rubykon 5 21 5 21 50 10 50 10
sudoku 5 48 5 51 50 163 50 160
tinygql 5 36 5 38 50 23 50 33
30k_ifelse 5 28 5 27 50 215 50 184
30k_methods 5 39 5 38 50 481 50 469
cfunc_itself 5 358 5 355 50 1137 50 1258
fib 5 127 5 142 50 902 50 932
getivar 5 213 5 310 50 2250 50 2400
keyword_args 5 104 5 108 50 1034 50 1243
loops-times 5 24 5 27 50 48 50 62
object-new 5 322 5 354 50 406 50 576
respond_to 5 133 5 135 50 3257 50 3902
ruby-xor 5 245 5 249 50 800 50 1296
setivar 5 361 5 616 50 3188 50 5104
setivar_object 5 353 5 428 50 672 50 602
setivar_young 5 368 5 428 50 703 50 619
str_concat 5 396 5 451 50 975 50 1130
throw 5 1270 5 1305 50 1734 50 1731

Different Ruby configurations want different amounts of warmup. With no JIT, CRuby needs hardly any. YJIT warms up fairly quickly, while some JITs may start slower as they do more advanced compilation.

Benchmark YJIT Stats

Hover your cursor over the benchmark names for descriptions of each benchmark.

bench Exit Report Inline Outlined Comp iSeqs Comp Blocks Inval Inval Ratio Bind Alloc Bind Set Const Bumps Compile Time MS
activerecord (click) 1494402 1233515 206 2590 0 0% 0 0 75.851965
chunky-png (click) 308117 301423 74 1322 1 0% 0 0 38.179904
erubi-rails (click) 1965269 1730710 262 3716 21 0% 0 0 110.285458
hexapdf (click) 1487540 1331623 593 15618 39 0% 0 0 449.334012
liquid-c (click) 526882 514657 114 2217 5 0% 0 0 60.939715
liquid-compile (click) 431623 407868 146 2718 2 0% 0 0 80.946781
liquid-render (click) 613512 569936 131 2933 8 0% 0 0 81.571401
lobsters (click) 8532185 7175396 3172 63857 118 0% 0 0 2182.361555
mail (click) 791039 727749 342 7227 40 0% 0 0 204.793027
psych-load (click) 266282 242850 61 825 3 0% 0 0 24.565463
railsbench (click) 3387187 2983803 1653 20228 56 0% 0 0 592.990826
rubocop (click) 5886926 4925522 2885 61751 113 0% 4 0 1818.559786
ruby-lsp (click) 886199 725856 305 5956 29 0% 0 0 167.97491
sequel (click) 510984 424450 11 114 0 0% 0 0 4.122699
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.614186
blurhash (click) 52289 51444 27 603 0 0% 0 0 18.311481
erubi (click) 270155 218882 5 125 0 0% 0 0 3.87256
etanni (click) 30806 32125 8 108 0 0% 0 0 3.512241
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.126641
fluentd (click) 397001 350323 7 115 0 0% 0 0 3.813724
graphql (click) 459668 389563 66 1035 0 0% 0 0 28.420148
graphql-native (click) 399851 327463 37 399 0 0% 0 0 12.198392
lee (click) 321247 287871 45 1012 0 0% 0 0 30.661248
matmul (click) 11125 4603 8 132 0 0% 0 0 4.278654
nbody (click) 13890 20235 6 238 0 0% 0 0 5.854369
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.446487
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 115.007951
protoboeuf (click) 170142 177773 12 2836 0 0% 0 0 75.580387
protoboeuf-encode (click) 243031 283791 14 1815 0 0% 0 0 47.119064
rack (click) 276863 247108 31 496 0 0% 0 0 13.607313
ruby-json (click) 24673 22156 8 204 0 0% 0 0 5.876786
rubyboy (click) 694185 691190 177 6963 40 0% 0 0 179.780532
rubykon (click) 145853 169867 137 2066 3 0% 0 0 56.861613
sudoku (click) 52157 66291 7 871 0 0% 0 0 24.045354
tinygql (click) 284066 271457 58 983 5 0% 0 0 27.539981
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1967.603629
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 493.071895
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.489532
fib (click) 2659 2995 3 30 0 0% 0 0 1.116244
getivar (click) 3812 6802 3 78 0 0% 0 0 1.921891
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.798563
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.756637
object-new (click) 2406 2818 2 36 0 0% 0 0 1.095076
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.097378
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.709117
setivar (click) 2783 3726 3 46 0 0% 0 0 1.265254
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.411213
setivar_young (click) 4297 4867 4 63 0 0% 0 0 1.71733
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.465556
throw (click) 5953 4624 5 53 0 0% 0 0 1.801859

YJIT stats correspond to the YJIT stats exit report.

Note: currently, all stats are collected on x86_64, not ARM.

Raw JSON data files

All graphs and table data in this page comes from processing these data files, which come from benchmark runs.