YJIT Benchmarks

Details for Benchmarks at 2025-05-26 03:54:11 UTC

YJIT metrics from the yjit-bench suite using Ruby 2295384a5a.

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 86.9% faster than CRuby 3.5.0dev
  • 4.5% faster than YJIT 3.3.6
On railsbench it is
  • 99.7% faster than CRuby 3.5.0dev
  • 4.8% faster than YJIT 3.3.6
x86_64 runtime: 4 hours, 26 minutes
aarch64 runtime: 3 hours, 47 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 80 5 83 50 156 50 167
chunky-png 5 31 5 33 50 15 50 23
erubi-rails 5 16 5 15 50 10 50 10
hexapdf 5 10 5 10 50 10 50 10
liquid-c 5 419 5 419 50 584 50 621
liquid-compile 5 406 5 463 50 566 50 697
liquid-render 5 169 5 171 50 401 50 437
lobsters 5 20 5 19 50 10 50 10
mail 5 195 5 176 50 240 50 205
psych-load 5 10 5 10 50 10 50 10
railsbench 5 10 5 10 50 10 50 10
rubocop 5 156 5 157 50 248 50 259
ruby-lsp 5 158 5 160 50 248 50 248
sequel 5 426 5 427 50 594 50 587
binarytrees 5 84 5 83 50 146 50 134
blurhash 5 82 5 87 50 127 50 145
erubi 5 125 5 146 50 99 50 152
etanni 5 90 5 100 50 54 50 69
fannkuchredux 5 52 5 58 50 97 50 110
fluentd 5 63 5 61 50 25 50 31
graphql 5 85 5 85 50 57 50 54
graphql-native 5 40 5 56 50 10 50 18
lee 5 22 5 24 50 10 50 10
matmul 5 51 5 53 50 88 50 96
nbody 5 249 5 259 50 585 50 693
nqueens 5 120 5 125 50 75 50 546
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 174 5 179 50 621 50 728
protoboeuf-encode 5 179 5 203 50 327 50 773
rack 5 580 5 632 50 958 50 1050
ruby-json 5 84 5 82 50 50 50 48
rubyboy 5 10 5 10 50 10 50 10
rubykon 5 21 5 22 50 10 50 10
sudoku 5 48 5 51 50 163 50 158
tinygql 5 36 5 38 50 22 50 31
30k_ifelse 5 28 5 28 50 216 50 184
30k_methods 5 38 5 38 50 482 50 474
cfunc_itself 5 359 5 349 50 1147 50 1258
fib 5 127 5 143 50 902 50 931
getivar 5 213 5 303 50 2252 50 2392
keyword_args 5 104 5 109 50 1041 50 1243
loops-times 5 24 5 28 50 48 50 62
object-new 5 322 5 351 50 405 50 532
respond_to 5 134 5 132 50 3257 50 3899
ruby-xor 5 245 5 255 50 799 50 1295
setivar 5 361 5 622 50 3189 50 5095
setivar_object 5 354 5 444 50 672 50 682
setivar_young 5 367 5 443 50 703 50 726
str_concat 5 399 5 457 50 979 50 1136
throw 5 1274 5 1301 50 1733 50 1737

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 76.014712
chunky-png (click) 335755 285829 74 1322 1 0% 0 0 38.720258
erubi-rails (click) 1961761 1703501 262 3677 21 0% 0 0 102.87081
hexapdf (click) 1516386 1358386 594 15620 40 0% 0 0 454.032232
liquid-c (click) 532520 436773 114 2217 5 0% 0 0 62.396329
liquid-compile (click) 419560 408175 146 2746 2 0% 0 0 82.42203
liquid-render (click) 611086 559713 131 2933 8 0% 0 0 82.106348
lobsters (click) 8547551 7285463 3171 63886 118 0% 0 0 2148.543432
mail (click) 805105 774553 342 7237 40 0% 0 0 205.383579
psych-load (click) 273026 242585 61 825 3 0% 0 0 24.790006
railsbench (click) 3367132 2999083 1653 20197 56 0% 0 0 578.978819
rubocop (click) 5923730 4975117 2885 61751 113 0% 4 0 1795.299571
ruby-lsp (click) 891903 714036 305 5955 29 0% 0 0 163.716398
sequel (click) 513246 475008 11 114 0 0% 0 0 3.768358
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.589745
blurhash (click) 52289 51444 27 603 0 0% 0 0 18.244406
erubi (click) 230736 193545 5 125 0 0% 0 0 3.927543
etanni (click) 30806 32125 8 108 0 0% 0 0 3.514472
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.08603
fluentd (click) 420951 361612 7 115 0 0% 0 0 3.702743
graphql (click) 461575 391089 66 1035 0 0% 0 0 28.643345
graphql-native (click) 414015 380490 37 399 0 0% 0 0 11.065875
lee (click) 281504 237243 45 1012 0 0% 0 0 30.518707
matmul (click) 11125 4603 8 132 0 0% 0 0 4.24446
nbody (click) 13890 20235 6 238 0 0% 0 0 5.844774
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.31207
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 114.839074
protoboeuf (click) 170142 177773 12 2836 0 0% 0 0 74.93834
protoboeuf-encode (click) 243031 283791 14 1815 0 0% 0 0 46.907273
rack (click) 253956 225488 31 496 0 0% 0 0 13.358175
ruby-json (click) 24673 22156 8 204 0 0% 0 0 5.845795
rubyboy (click) 727747 680607 177 6963 40 0% 0 0 175.14414
rubykon (click) 146417 162602 137 2076 3 0% 0 0 57.359382
sudoku (click) 52157 66291 7 871 0 0% 0 0 24.068117
tinygql (click) 294221 242759 58 977 5 0% 0 0 27.117447
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1963.828731
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 491.951305
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.493315
fib (click) 2659 2995 3 30 0 0% 0 0 1.050452
getivar (click) 3812 6802 3 78 0 0% 0 0 1.922505
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.762757
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.735242
object-new (click) 2406 2818 2 36 0 0% 0 0 1.135888
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.088744
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.698514
setivar (click) 2783 3726 3 46 0 0% 0 0 1.234158
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.401959
setivar_young (click) 4297 4867 4 63 0 0% 0 0 1.718164
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.487083
throw (click) 5953 4624 5 53 0 0% 0 0 1.772381

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.