YJIT Benchmarks

Details for Benchmarks at 2025-05-24 03:48:58 UTC

YJIT metrics from the yjit-bench suite using Ruby 87d340f0e1.

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 87.0% faster than CRuby 3.5.0dev
  • 4.9% faster than YJIT 3.3.6
On railsbench it is
  • 99.7% faster than CRuby 3.5.0dev
  • 7.9% faster than YJIT 3.3.6
x86_64 runtime: 4 hours, 26 minutes
aarch64 runtime: 3 hours, 44 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 82 5 82 50 154 50 164
chunky-png 5 31 5 33 50 14 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 425 50 582 50 622
liquid-compile 5 404 5 465 50 541 50 701
liquid-render 5 169 5 169 50 401 50 439
lobsters 5 19 5 19 50 10 50 10
mail 5 194 5 184 50 249 50 203
psych-load 5 10 5 10 50 10 50 10
railsbench 5 10 5 10 50 10 50 10
rubocop 5 156 5 156 50 251 50 259
ruby-lsp 5 154 5 157 50 258 50 247
sequel 5 426 5 424 50 596 50 584
binarytrees 5 84 5 84 50 146 50 133
blurhash 5 82 5 87 50 127 50 145
erubi 5 124 5 135 50 34 50 148
etanni 5 91 5 100 50 53 50 68
fannkuchredux 5 52 5 58 50 98 50 112
fluentd 5 63 5 63 50 25 50 26
graphql 5 85 5 85 50 58 50 54
graphql-native 5 40 5 55 50 10 50 17
lee 5 23 5 24 50 10 50 10
matmul 5 51 5 53 50 88 50 97
nbody 5 248 5 261 50 585 50 688
nqueens 5 120 5 128 50 75 50 556
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 172 5 184 50 620 50 727
protoboeuf-encode 5 179 5 174 50 327 50 791
rack 5 590 5 635 50 942 50 1056
ruby-json 5 84 5 83 50 49 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 160
tinygql 5 35 5 36 50 22 50 34
30k_ifelse 5 28 5 27 50 212 50 184
30k_methods 5 39 5 38 50 479 50 471
cfunc_itself 5 359 5 345 50 1147 50 1258
fib 5 127 5 141 50 902 50 931
getivar 5 213 5 289 50 2253 50 2385
keyword_args 5 104 5 107 50 1041 50 1243
loops-times 5 24 5 27 50 48 50 62
object-new 5 322 5 352 50 405 50 531
respond_to 5 134 5 135 50 3257 50 3899
ruby-xor 5 244 5 259 50 799 50 1296
setivar 5 361 5 606 50 3177 50 5095
setivar_object 5 354 5 447 50 671 50 684
setivar_young 5 367 5 447 50 702 50 726
str_concat 5 399 5 463 50 978 50 1134
throw 5 1271 5 1307 50 1718 50 1736

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) 1519338 1191980 206 2590 0 0% 0 0 75.370013
chunky-png (click) 310589 278751 74 1322 1 0% 0 0 38.544697
erubi-rails (click) 1972584 1779000 262 3632 21 0% 0 0 100.744893
hexapdf (click) 1488122 1266663 594 15612 39 0% 0 0 452.917518
liquid-c (click) 529692 524831 114 2217 5 0% 0 0 61.456158
liquid-compile (click) 450035 409613 146 2700 2 0% 0 0 81.131784
liquid-render (click) 632764 556085 131 2933 8 0% 0 0 81.170488
lobsters (click) 8513760 7059372 3172 63589 120 0% 0 0 2161.417008
mail (click) 817379 776525 342 7227 40 0% 0 0 210.72887
psych-load (click) 294704 252800 61 825 3 0% 0 0 24.903843
railsbench (click) 3379650 2762276 1653 20174 56 0% 0 0 578.2426
rubocop (click) 5894780 4939834 2885 61732 113 0% 4 0 1810.714397
ruby-lsp (click) 884180 765123 305 5955 29 0% 0 0 166.617931
sequel (click) 512046 416647 11 114 0 0% 0 0 4.154868
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.642208
blurhash (click) 52289 51444 27 603 0 0% 0 0 18.152066
erubi (click) 271324 254012 5 125 0 0% 0 0 3.882541
etanni (click) 30806 32125 8 108 0 0% 0 0 3.520593
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.067187
fluentd (click) 421053 370675 7 115 0 0% 0 0 3.648962
graphql (click) 432996 357352 66 1035 0 0% 0 0 28.456332
graphql-native (click) 414315 356356 37 399 0 0% 0 0 11.225558
lee (click) 293721 253935 45 1012 0 0% 0 0 30.469966
matmul (click) 11125 4603 8 132 0 0% 0 0 4.247599
nbody (click) 13890 20235 6 238 0 0% 0 0 5.778463
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.386583
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 113.692911
protoboeuf (click) 170142 177773 12 2836 0 0% 0 0 75.255916
protoboeuf-encode (click) 243031 283791 14 1815 0 0% 0 0 46.588314
rack (click) 252496 199509 31 496 0 0% 0 0 13.672515
ruby-json (click) 24668 22156 8 204 0 0% 0 0 5.762318
rubyboy (click) 698833 655595 177 6963 40 0% 0 0 174.803149
rubykon (click) 145853 169867 137 2066 3 0% 0 0 57.000851
sudoku (click) 52157 66291 7 871 0 0% 0 0 23.924051
tinygql (click) 308068 253966 58 977 5 0% 0 0 27.438307
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1971.218915
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 493.137002
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.452841
fib (click) 2659 2995 3 30 0 0% 0 0 1.082462
getivar (click) 3812 6802 3 78 0 0% 0 0 1.882437
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.768413
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.761601
object-new (click) 2406 2818 2 36 0 0% 0 0 1.083156
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.090756
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.714943
setivar (click) 2783 3726 3 46 0 0% 0 0 1.232292
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.411218
setivar_young (click) 4297 4867 4 63 0 0% 0 0 1.672459
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.498263
throw (click) 5953 4624 5 53 0 0% 0 0 1.813224

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.