YJIT Benchmarks

Details for Benchmarks at 2025-06-07 03:52:15 UTC

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

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 88.7% faster than CRuby 3.5.0dev
  • 4.1% faster than YJIT 3.3.6
On railsbench it is
  • 99.3% faster than CRuby 3.5.0dev
  • 5.4% faster than YJIT 3.3.6
x86_64 runtime: 4 hours, 26 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 81 5 83 50 155 50 165
chunky-png 5 31 5 31 50 14 50 25
erubi-rails 5 16 5 14 50 10 50 10
hexapdf 5 10 5 10 50 10 50 10
liquid-c 5 419 5 421 50 587 50 600
liquid-compile 5 405 5 466 50 539 50 672
liquid-render 5 171 5 169 50 403 50 431
lobsters 5 19 5 19 50 10 50 10
mail 5 195 5 174 50 250 50 206
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 161 5 157 50 259 50 251
sequel 5 426 5 416 50 597 50 585
binarytrees 5 84 5 80 50 146 50 121
blurhash 5 82 5 86 50 127 50 145
erubi 5 115 5 134 50 99 50 147
etanni 5 91 5 101 50 53 50 69
fannkuchredux 5 52 5 57 50 97 50 104
fluentd 5 63 5 60 50 25 50 31
graphql 5 85 5 84 50 58 50 54
graphql-native 5 40 5 54 50 10 50 16
lee 5 23 5 24 50 10 50 10
matmul 5 51 5 48 50 88 50 92
nbody 5 249 5 233 50 584 50 690
nqueens 5 120 5 126 50 75 50 516
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 174 5 180 50 620 50 734
protoboeuf-encode 5 178 5 199 50 325 50 796
rack 5 589 5 627 50 950 50 1049
ruby-json 5 84 5 82 50 50 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 149
tinygql 5 36 5 37 50 22 50 33
30k_ifelse 5 28 5 27 50 215 50 183
30k_methods 5 38 5 38 50 481 50 471
cfunc_itself 5 358 5 344 50 1147 50 1258
fib 5 127 5 138 50 902 50 931
getivar 5 213 5 288 50 2249 50 2378
keyword_args 5 104 5 108 50 1041 50 1243
loops-times 5 24 5 25 50 48 50 56
object-new 5 322 5 360 50 405 50 605
respond_to 5 134 5 132 50 3257 50 3897
ruby-xor 5 245 5 244 50 799 50 1295
setivar 5 361 5 447 50 3192 50 5004
setivar_object 5 353 5 412 50 671 50 593
setivar_young 5 368 5 410 50 702 50 614
str_concat 5 399 5 451 50 980 50 1185
throw 5 1269 5 1262 50 1704 50 1660

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) 1522241 1324237 206 2590 0 0% 0 0 75.540434
chunky-png (click) 317777 278329 74 1322 1 0% 0 0 38.744993
erubi-rails (click) 1959905 1717953 262 3678 21 0% 0 0 102.797815
hexapdf (click) 1517198 1400130 593 15627 40 0% 0 0 457.366336
liquid-c (click) 498758 489498 114 2217 5 0% 0 0 62.174649
liquid-compile (click) 459214 392392 146 2709 2 0% 0 0 81.190922
liquid-render (click) 641559 587548 131 2933 8 0% 0 0 81.285316
lobsters (click) 8535728 7300471 3173 63890 119 0% 0 0 2159.57392
mail (click) 794431 763606 342 7267 40 0% 0 0 208.128418
psych-load (click) 268017 238116 61 825 3 0% 0 0 24.779971
railsbench (click) 3376575 2982785 1653 20220 56 0% 0 0 583.667965
rubocop (click) 5902939 5040006 2885 61711 114 0% 4 0 1808.985185
ruby-lsp (click) 855008 744214 305 5949 29 0% 0 0 163.210231
sequel (click) 477538 433473 11 114 0 0% 0 0 4.112668
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.64184
blurhash (click) 52289 51444 27 603 0 0% 0 0 18.417889
erubi (click) 244586 204005 5 125 0 0% 0 0 3.948829
etanni (click) 30806 32125 8 108 0 0% 0 0 3.539412
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.168022
fluentd (click) 421342 353859 7 115 0 0% 0 0 3.773781
graphql (click) 432973 358935 66 1035 0 0% 0 0 28.686818
graphql-native (click) 385450 321296 37 399 0 0% 0 0 11.380909
lee (click) 320492 286795 45 1012 0 0% 0 0 30.699537
matmul (click) 11125 4603 8 132 0 0% 0 0 4.247303
nbody (click) 13890 20235 6 238 0 0% 0 0 5.865393
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.445078
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 113.475176
protoboeuf (click) 170142 177773 12 2836 0 0% 0 0 76.774119
protoboeuf-encode (click) 243031 283791 14 1815 0 0% 0 0 47.077207
rack (click) 280191 224886 31 496 0 0% 0 0 13.189612
ruby-json (click) 24673 22156 8 204 0 0% 0 0 5.893688
rubyboy (click) 702785 657657 177 6971 40 0% 0 0 176.68632
rubykon (click) 145853 169867 137 2066 3 0% 0 0 57.206866
sudoku (click) 52157 66291 7 871 0 0% 0 0 24.116765
tinygql (click) 316880 269373 58 983 5 0% 0 0 27.561114
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1976.284818
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 493.794415
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.457967
fib (click) 2659 2995 3 30 0 0% 0 0 1.085248
getivar (click) 3812 6802 3 78 0 0% 0 0 1.918164
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.780135
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.73918
object-new (click) 2406 2818 2 36 0 0% 0 0 1.131629
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.10338
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.74829
setivar (click) 2783 3726 3 46 0 0% 0 0 1.277499
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.421946
setivar_young (click) 4297 4867 4 63 0 0% 0 0 1.718221
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.469981
throw (click) 5953 4624 5 53 0 0% 0 0 1.814778

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.