YJIT Benchmarks

Details for Benchmarks at 2025-06-01 04:01:16 UTC

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

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 88.8% faster than CRuby 3.5.0dev
  • 5.6% faster than YJIT 3.3.6
On railsbench it is
  • 102.6% faster than CRuby 3.5.0dev
  • 5.1% faster than YJIT 3.3.6
x86_64 runtime: 4 hours, 26 minutes
aarch64 runtime: 3 hours, 46 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 84 50 156 50 175
chunky-png 5 31 5 32 50 14 50 23
erubi-rails 5 15 5 14 50 10 50 10
hexapdf 5 10 5 10 50 10 50 10
liquid-c 5 406 5 422 50 563 50 617
liquid-compile 5 424 5 464 50 538 50 674
liquid-render 5 169 5 169 50 402 50 430
lobsters 5 20 5 19 50 10 50 10
mail 5 194 5 168 50 250 50 201
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 249 50 262
ruby-lsp 5 155 5 161 50 246 50 265
sequel 5 428 5 423 50 569 50 585
binarytrees 5 84 5 80 50 145 50 134
blurhash 5 82 5 87 50 127 50 145
erubi 5 116 5 135 50 86 50 145
etanni 5 91 5 98 50 53 50 68
fannkuchredux 5 52 5 58 50 97 50 108
fluentd 5 63 5 59 50 25 50 29
graphql 5 84 5 82 50 57 50 58
graphql-native 5 40 5 55 50 10 50 20
lee 5 22 5 24 50 10 50 10
matmul 5 51 5 53 50 88 50 96
nbody 5 249 5 257 50 585 50 689
nqueens 5 120 5 127 50 75 50 554
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 175 5 186 50 620 50 756
protoboeuf-encode 5 178 5 203 50 328 50 793
rack 5 585 5 640 50 950 50 1048
ruby-json 5 83 5 82 50 50 50 49
rubyboy 5 10 5 10 50 10 50 10
rubykon 5 20 5 21 50 10 50 10
sudoku 5 48 5 51 50 163 50 159
tinygql 5 36 5 38 50 21 50 32
30k_ifelse 5 28 5 27 50 216 50 185
30k_methods 5 39 5 38 50 481 50 468
cfunc_itself 5 357 5 355 50 1147 50 1258
fib 5 127 5 140 50 902 50 931
getivar 5 214 5 308 50 2250 50 2391
keyword_args 5 104 5 108 50 1042 50 1243
loops-times 5 24 5 26 50 48 50 60
object-new 5 322 5 356 50 405 50 559
respond_to 5 133 5 129 50 3257 50 3902
ruby-xor 5 245 5 252 50 800 50 1296
setivar 5 361 5 622 50 3187 50 5097
setivar_object 5 354 5 445 50 671 50 744
setivar_young 5 368 5 444 50 702 50 755
str_concat 5 399 5 450 50 979 50 1125
throw 5 1269 5 1278 50 1725 50 1700

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) 1494443 1209040 206 2590 0 0% 0 0 75.695255
chunky-png (click) 328897 279471 74 1322 1 0% 0 0 38.386986
erubi-rails (click) 1960839 1668527 262 3609 21 0% 0 0 100.555494
hexapdf (click) 1490835 1325759 594 15615 39 0% 0 0 446.338831
liquid-c (click) 502799 467197 114 2217 5 0% 0 0 62.488216
liquid-compile (click) 457391 431469 146 2709 2 0% 0 0 82.033513
liquid-render (click) 626604 541766 131 2933 8 0% 0 0 81.119405
lobsters (click) 8528646 7164472 3170 63823 118 0% 0 0 2176.511494
mail (click) 780574 678209 342 7229 40 0% 0 0 209.411413
psych-load (click) 290370 240718 61 822 3 0% 0 0 24.750752
railsbench (click) 3406316 2969364 1653 20229 56 0% 0 0 583.924722
rubocop (click) 5912394 5088495 2885 61702 113 0% 4 0 1792.3104
ruby-lsp (click) 858409 722806 305 5956 29 0% 0 0 164.722696
sequel (click) 516553 453842 11 114 0 0% 0 0 4.034133
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.619299
blurhash (click) 52289 51444 27 603 0 0% 0 0 18.272658
erubi (click) 245517 203906 5 125 0 0% 0 0 3.929278
etanni (click) 30806 32125 8 108 0 0% 0 0 3.508628
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.187173
fluentd (click) 421610 370604 7 115 0 0% 0 0 3.781122
graphql (click) 432783 380680 66 1035 0 0% 0 0 29.0312
graphql-native (click) 418404 351793 37 399 0 0% 0 0 11.368982
lee (click) 296280 223028 45 1012 0 0% 0 0 30.285924
matmul (click) 11125 4603 8 132 0 0% 0 0 4.286419
nbody (click) 13890 20235 6 238 0 0% 0 0 5.89224
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.452457
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 113.923113
protoboeuf (click) 170142 177773 12 2836 0 0% 0 0 75.762074
protoboeuf-encode (click) 243031 283791 14 1815 0 0% 0 0 46.930117
rack (click) 250923 206476 31 496 0 0% 0 0 13.938031
ruby-json (click) 20449 18419 8 204 0 0% 0 0 5.847267
rubyboy (click) 714274 669737 177 6963 40 0% 0 0 175.910955
rubykon (click) 147890 164247 137 2092 3 0% 0 0 57.947589
sudoku (click) 52157 66291 7 871 0 0% 0 0 24.164925
tinygql (click) 311174 264597 58 977 5 0% 0 0 27.181133
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1981.888792
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 491.103446
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.529177
fib (click) 2659 2995 3 30 0 0% 0 0 1.089039
getivar (click) 3812 6802 3 78 0 0% 0 0 1.914738
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.786986
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.773593
object-new (click) 2406 2818 2 36 0 0% 0 0 1.120119
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.082326
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.729762
setivar (click) 2783 3726 3 46 0 0% 0 0 1.258776
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.41216
setivar_young (click) 4297 4867 4 63 0 0% 0 0 1.72051
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.468347
throw (click) 5953 4624 5 53 0 0% 0 0 1.802885

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.