YJIT Benchmarks

Details for Benchmarks at 2025-06-18 03:55:31 UTC

YJIT metrics from the yjit-bench suite using Ruby 3cfd71e7e4.

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 91.2% faster than CRuby 3.5.0dev
  • 4.7% faster than YJIT 3.3.6
On railsbench it is
  • 105.8% faster than CRuby 3.5.0dev
  • 8.1% 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 156 50 167
chunky-png 5 31 5 32 50 14 50 23
erubi-rails 5 16 5 14 50 10 50 10
hexapdf 5 10 5 10 50 10 50 10
liquid-c 5 407 5 418 50 585 50 618
liquid-compile 5 408 5 453 50 543 50 666
liquid-render 5 171 5 172 50 404 50 435
lobsters 5 19 5 19 50 10 50 10
mail 5 190 5 174 50 237 50 194
psych-load 5 10 5 10 50 10 50 10
railsbench 5 10 5 10 50 10 50 10
rubocop 5 157 5 154 50 247 50 255
ruby-lsp 5 155 5 151 50 239 50 256
sequel 5 415 5 418 50 573 50 574
binarytrees 5 84 5 79 50 146 50 118
blurhash 5 82 5 84 50 127 50 145
erubi 5 114 5 139 50 89 50 150
etanni 5 90 5 100 50 53 50 71
fannkuchredux 5 52 5 56 50 97 50 99
fluentd 5 64 5 60 50 25 50 30
graphql 5 85 5 82 50 58 50 54
graphql-native 5 40 5 44 50 11 50 15
lee 5 22 5 21 50 10 50 10
matmul 5 51 5 48 50 88 50 91
nbody 5 249 5 228 50 585 50 698
nqueens 5 120 5 125 50 75 50 526
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 173 5 155 50 620 50 757
protoboeuf-encode 5 178 5 202 50 326 50 783
rack 5 573 5 606 50 954 50 1057
ruby-json 5 84 5 82 50 50 50 48
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 149
tinygql 5 36 5 35 50 22 50 32
30k_ifelse 5 28 5 27 50 216 50 184
30k_methods 5 38 5 38 50 475 50 477
cfunc_itself 5 358 5 340 50 1147 50 1258
fib 5 127 5 139 50 902 50 931
getivar 5 213 5 304 50 2251 50 2400
keyword_args 5 104 5 99 50 1041 50 1243
loops-times 5 24 5 25 50 48 50 56
object-new 5 322 5 359 50 405 50 590
respond_to 5 134 5 135 50 3257 50 3904
ruby-xor 5 245 5 248 50 799 50 1296
setivar 5 361 5 372 50 3193 50 4950
setivar_object 5 354 5 360 50 672 50 618
setivar_young 5 368 5 361 50 702 50 652
str_concat 5 399 5 446 50 982 50 1131
throw 5 1269 5 1245 50 1722 50 1710

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) 1515980 1245604 206 2590 0 0% 0 0 75.478969
chunky-png (click) 328044 311942 74 1322 1 0% 0 0 39.7512
erubi-rails (click) 1988895 1710399 263 3659 21 0% 0 0 101.250269
hexapdf (click) 1492181 1351892 593 15614 40 0% 0 0 453.045637
liquid-c (click) 504005 419086 114 2217 5 0% 0 0 61.514663
liquid-compile (click) 430778 374220 146 2717 2 0% 0 0 80.478568
liquid-render (click) 612857 503919 131 2933 8 0% 0 0 81.907353
lobsters (click) 8533715 7299242 3170 63975 118 0% 0 0 2145.893999
mail (click) 791111 735352 342 7227 40 0% 0 0 205.579824
psych-load (click) 266658 218595 61 825 3 0% 0 0 24.724347
railsbench (click) 3384673 2871963 1653 20227 56 0% 0 0 583.387062
rubocop (click) 5892335 5190674 2885 61697 114 0% 4 0 1904.60391
ruby-lsp (click) 892372 804190 305 5956 29 0% 0 0 164.37009
sequel (click) 480319 437555 11 115 0 0% 0 0 4.018432
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.62138
blurhash (click) 52295 51444 27 603 0 0% 0 0 18.218289
erubi (click) 261462 236121 5 125 0 0% 0 0 3.985816
etanni (click) 30806 32125 8 108 0 0% 0 0 3.47105
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.09251
fluentd (click) 418006 367840 7 115 0 0% 0 0 3.856362
graphql (click) 430788 387658 66 1035 0 0% 0 0 28.305481
graphql-native (click) 407186 350418 37 399 0 0% 0 0 11.149394
lee (click) 313490 281236 45 1012 0 0% 0 0 30.545293
matmul (click) 11125 4603 8 132 0 0% 0 0 4.201604
nbody (click) 13890 20235 6 238 0 0% 0 0 5.890367
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.351903
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 113.805902
protoboeuf (click) 170160 177773 12 2836 0 0% 0 0 75.782789
protoboeuf-encode (click) 243046 283791 14 1815 0 0% 0 0 47.310608
rack (click) 252826 199671 31 496 0 0% 0 0 13.490323
ruby-json (click) 20449 18419 8 204 0 0% 0 0 5.803883
rubyboy (click) 728699 705449 177 6919 40 0% 0 0 179.897939
rubykon (click) 147914 164247 137 2092 3 0% 0 0 57.802964
sudoku (click) 52157 66291 7 871 0 0% 0 0 24.171707
tinygql (click) 288322 267451 58 977 5 0% 0 0 27.277451
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1970.058799
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 495.385754
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.499172
fib (click) 2659 2995 3 30 0 0% 0 0 1.042915
getivar (click) 3812 6802 3 78 0 0% 0 0 1.925432
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.77592
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.830154
object-new (click) 2406 2818 2 36 0 0% 0 0 1.12228
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.12107
ruby-xor (click) 5863 8622 4 100 0 0% 0 0 2.731188
setivar (click) 2783 3726 3 46 0 0% 0 0 1.231017
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.403646
setivar_young (click) 4300 4867 4 63 0 0% 0 0 1.717191
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.457574
throw (click) 5953 4624 5 53 0 0% 0 0 1.808292

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.