YJIT Benchmarks

Details for Benchmarks at 2025-06-05 03:55:15 UTC

YJIT metrics from the yjit-bench suite using Ruby 111986f8b0.

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 92.7% faster than CRuby 3.5.0dev
  • 7.4% faster than YJIT 3.3.6
On railsbench it is
  • 106.4% faster than CRuby 3.5.0dev
  • 6.1% 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 83 5 82 50 155 50 171
chunky-png 5 31 5 32 50 15 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 425 50 589 50 611
liquid-compile 5 408 5 463 50 541 50 700
liquid-render 5 169 5 172 50 404 50 436
lobsters 5 20 5 19 50 10 50 10
mail 5 188 5 176 50 250 50 222
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 249 50 262
ruby-lsp 5 145 5 156 50 242 50 267
sequel 5 416 5 416 50 569 50 583
binarytrees 5 84 5 80 50 146 50 133
blurhash 5 82 5 85 50 127 50 145
erubi 5 116 5 134 50 87 50 152
etanni 5 90 5 101 50 53 50 72
fannkuchredux 5 52 5 58 50 97 50 103
fluentd 5 63 5 63 50 25 50 29
graphql 5 85 5 85 50 58 50 58
graphql-native 5 39 5 55 50 10 50 14
lee 5 23 5 23 50 10 50 10
matmul 5 51 5 51 50 88 50 90
nbody 5 249 5 237 50 585 50 624
nqueens 5 120 5 127 50 75 50 523
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 174 5 185 50 620 50 730
protoboeuf-encode 5 179 5 200 50 327 50 801
rack 5 585 5 635 50 950 50 1047
ruby-json 5 83 5 84 50 49 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 150
tinygql 5 36 5 39 50 22 50 35
30k_ifelse 5 28 5 27 50 216 50 184
30k_methods 5 39 5 38 50 481 50 474
cfunc_itself 5 358 5 368 50 1137 50 1258
fib 5 127 5 139 50 902 50 931
getivar 5 213 5 287 50 2252 50 2378
keyword_args 5 104 5 109 50 1034 50 1243
loops-times 5 24 5 25 50 48 50 55
object-new 5 322 5 356 50 406 50 597
respond_to 5 133 5 130 50 3255 50 3901
ruby-xor 5 245 5 250 50 799 50 1296
setivar 5 361 5 398 50 3186 50 4955
setivar_object 5 353 5 378 50 671 50 627
setivar_young 5 368 5 378 50 702 50 663
str_concat 5 400 5 463 50 983 50 1185
throw 5 1270 5 1279 50 1719 50 1713

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) 1487536 1228682 206 2590 0 0% 0 0 75.191491
chunky-png (click) 301910 288765 74 1330 1 0% 0 0 39.772416
erubi-rails (click) 1981429 1686278 262 3609 21 0% 0 0 100.343274
hexapdf (click) 1509986 1386354 593 15626 41 0% 0 0 458.798863
liquid-c (click) 524190 488129 114 2217 5 0% 0 0 62.057688
liquid-compile (click) 457110 415284 146 2714 2 0% 0 0 80.892365
liquid-render (click) 640141 570193 131 2933 8 0% 0 0 83.659117
lobsters (click) 8542492 7232263 3173 63914 118 0% 0 0 2153.564986
mail (click) 818505 728530 342 7227 40 0% 0 0 208.043743
psych-load (click) 293984 268521 61 825 3 0% 0 0 24.554622
railsbench (click) 3387998 3072055 1653 20166 56 0% 0 0 577.227903
rubocop (click) 5897260 4828526 2885 61752 113 0% 4 0 1811.318957
ruby-lsp (click) 853263 729488 305 5950 29 0% 0 0 167.384317
sequel (click) 468794 427101 11 116 0 0% 0 0 3.658343
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.632861
blurhash (click) 52289 51444 27 603 0 0% 0 0 18.38977
erubi (click) 235731 205285 5 125 0 0% 0 0 3.906597
etanni (click) 30806 32125 8 108 0 0% 0 0 3.50819
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.234457
fluentd (click) 423662 331041 7 115 0 0% 0 0 3.758176
graphql (click) 462231 407771 66 1035 0 0% 0 0 28.73743
graphql-native (click) 389604 325053 37 399 0 0% 0 0 11.285395
lee (click) 297599 225205 45 1012 0 0% 0 0 30.172564
matmul (click) 11125 4603 8 132 0 0% 0 0 4.212872
nbody (click) 13890 20235 6 238 0 0% 0 0 5.879908
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.463848
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 113.286197
protoboeuf (click) 170142 177773 12 2836 0 0% 0 0 75.725847
protoboeuf-encode (click) 243031 283791 14 1815 0 0% 0 0 47.209207
rack (click) 273087 235783 31 496 0 0% 0 0 13.23659
ruby-json (click) 24392 21840 8 204 0 0% 0 0 5.807181
rubyboy (click) 728820 680801 177 6921 40 0% 0 0 177.175691
rubykon (click) 145425 177646 137 2062 3 0% 0 0 57.064912
sudoku (click) 52157 66291 7 871 0 0% 0 0 24.184553
tinygql (click) 281091 246077 58 977 5 0% 0 0 27.363925
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1968.532587
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 494.796227
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.480091
fib (click) 2659 2995 3 30 0 0% 0 0 1.099233
getivar (click) 3812 6802 3 78 0 0% 0 0 1.93551
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.7691
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.802025
object-new (click) 2406 2818 2 36 0 0% 0 0 1.127865
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.125229
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.749833
setivar (click) 2783 3726 3 46 0 0% 0 0 1.273479
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.423818
setivar_young (click) 4297 4867 4 63 0 0% 0 0 1.733644
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.50189
throw (click) 5953 4624 5 53 0 0% 0 0 1.821808

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.