YJIT Benchmarks

Details for Benchmarks at 2025-06-08 03:58:05 UTC

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

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 94.1% faster than CRuby 3.5.0dev
  • 6.2% faster than YJIT 3.3.6
On railsbench it is
  • 103.6% faster than CRuby 3.5.0dev
  • 4.3% faster than YJIT 3.3.6
x86_64 runtime: 4 hours, 27 minutes
aarch64 runtime: 3 hours, 45 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 83 5 76 50 145 50 158
chunky-png 5 31 5 32 50 15 50 25
erubi-rails 5 15 5 14 50 10 50 10
hexapdf 5 10 5 10 50 10 50 10
liquid-c 5 420 5 416 50 559 50 621
liquid-compile 5 407 5 456 50 541 50 698
liquid-render 5 169 5 172 50 404 50 436
lobsters 5 20 5 19 50 10 50 10
mail 5 194 5 170 50 235 50 208
psych-load 5 10 5 10 50 10 50 10
railsbench 5 10 5 10 50 10 50 10
rubocop 5 156 5 155 50 251 50 258
ruby-lsp 5 158 5 152 50 256 50 265
sequel 5 424 5 414 50 597 50 585
binarytrees 5 84 5 80 50 146 50 117
blurhash 5 82 5 87 50 127 50 145
erubi 5 124 5 135 50 88 50 155
etanni 5 90 5 103 50 53 50 72
fannkuchredux 5 52 5 58 50 98 50 101
fluentd 5 63 5 65 50 24 50 27
graphql 5 85 5 84 50 59 50 51
graphql-native 5 40 5 45 50 10 50 16
lee 5 22 5 23 50 10 50 10
matmul 5 51 5 50 50 88 50 91
nbody 5 249 5 238 50 585 50 692
nqueens 5 120 5 127 50 75 50 527
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 174 5 160 50 621 50 750
protoboeuf-encode 5 178 5 203 50 325 50 802
rack 5 583 5 618 50 961 50 1047
ruby-json 5 84 5 85 50 50 50 51
rubyboy 5 10 5 10 50 10 50 10
rubykon 5 20 5 22 50 10 50 10
sudoku 5 48 5 51 50 163 50 151
tinygql 5 36 5 35 50 22 50 33
30k_ifelse 5 28 5 27 50 215 50 184
30k_methods 5 39 5 38 50 477 50 472
cfunc_itself 5 358 5 347 50 1146 50 1258
fib 5 127 5 142 50 903 50 931
getivar 5 213 5 302 50 2252 50 2392
keyword_args 5 104 5 109 50 1040 50 1243
loops-times 5 24 5 26 50 48 50 56
object-new 5 322 5 362 50 405 50 592
respond_to 5 134 5 134 50 3257 50 3900
ruby-xor 5 245 5 250 50 800 50 1296
setivar 5 361 5 440 50 3196 50 5012
setivar_object 5 354 5 426 50 671 50 622
setivar_young 5 368 5 426 50 704 50 657
str_concat 5 399 5 466 50 985 50 1182
throw 5 1274 5 1291 50 1707 50 1689

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) 1525652 1285957 206 2590 0 0% 0 0 76.001164
chunky-png (click) 293272 265342 74 1322 1 0% 0 0 38.995343
erubi-rails (click) 1963112 1760008 262 3673 21 0% 0 0 102.618472
hexapdf (click) 1481487 1383969 593 15690 35 0% 0 0 459.044587
liquid-c (click) 495023 462684 114 2217 5 0% 0 0 60.654534
liquid-compile (click) 429540 390259 146 2722 2 0% 0 0 82.682043
liquid-render (click) 604788 507149 131 2933 8 0% 0 0 81.004937
lobsters (click) 8517540 7203421 3169 63609 119 0% 0 0 2142.020112
mail (click) 809330 793743 342 7227 40 0% 0 0 205.350465
psych-load (click) 295431 260937 61 822 3 0% 0 0 24.417789
railsbench (click) 3406168 2982305 1653 20222 56 0% 0 0 581.60009
rubocop (click) 5905301 5016079 2885 61694 114 0% 4 0 1917.352695
ruby-lsp (click) 877699 800489 305 5956 29 0% 0 0 167.153386
sequel (click) 499746 446066 11 117 0 0% 0 0 4.315132
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.620813
blurhash (click) 52295 51444 27 603 0 0% 0 0 18.331913
erubi (click) 272818 245593 5 125 0 0% 0 0 3.89888
etanni (click) 30806 32125 8 108 0 0% 0 0 3.523576
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.154662
fluentd (click) 421528 370343 7 115 0 0% 0 0 3.737816
graphql (click) 433837 350315 66 1035 0 0% 0 0 28.726049
graphql-native (click) 415644 372974 37 399 0 0% 0 0 11.316744
lee (click) 306633 282860 45 1012 0 0% 0 0 30.798438
matmul (click) 11125 4603 8 132 0 0% 0 0 4.201103
nbody (click) 13890 20235 6 238 0 0% 0 0 5.91736
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.408884
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 113.090694
protoboeuf (click) 170160 177773 12 2836 0 0% 0 0 76.320036
protoboeuf-encode (click) 243046 283791 14 1815 0 0% 0 0 47.15306
rack (click) 281568 242374 31 496 0 0% 0 0 13.13471
ruby-json (click) 24637 22156 8 204 0 0% 0 0 5.742565
rubyboy (click) 731846 667116 177 6977 40 0% 0 0 177.427539
rubykon (click) 146441 162602 137 2076 3 0% 0 0 57.219445
sudoku (click) 52157 66291 7 871 0 0% 0 0 23.960834
tinygql (click) 314710 283676 58 971 5 0% 0 0 26.895168
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1970.630314
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 492.338784
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.479631
fib (click) 2659 2995 3 30 0 0% 0 0 1.054925
getivar (click) 3812 6802 3 78 0 0% 0 0 1.896855
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.784763
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.811126
object-new (click) 2406 2818 2 36 0 0% 0 0 1.106372
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.100923
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.714361
setivar (click) 2783 3726 3 46 0 0% 0 0 1.245195
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.384284
setivar_young (click) 4300 4867 4 63 0 0% 0 0 1.719708
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.482906
throw (click) 5953 4624 5 53 0 0% 0 0 1.803261

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.