YJIT Benchmarks

Details for Benchmarks at 2025-05-30 03:51:43 UTC

YJIT metrics from the yjit-bench suite using Ruby 9f91f3617b.

Using the geomean of the headline benchmarks for x86 YJIT 3.5.0dev is
  • 91.1% faster than CRuby 3.5.0dev
  • 6.1% faster than YJIT 3.3.6
On railsbench it is
  • 100.8% faster than CRuby 3.5.0dev
  • 6.2% 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 84 5 82 50 158 50 168
chunky-png 5 31 5 32 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 420 5 420 50 573 50 623
liquid-compile 5 410 5 457 50 541 50 675
liquid-render 5 170 5 169 50 402 50 436
lobsters 5 20 5 19 50 10 50 10
mail 5 195 5 176 50 250 50 220
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 250 50 260
ruby-lsp 5 161 5 158 50 255 50 267
sequel 5 428 5 425 50 597 50 593
binarytrees 5 84 5 83 50 146 50 134
blurhash 5 82 5 88 50 127 50 145
erubi 5 117 5 138 50 97 50 137
etanni 5 91 5 98 50 54 50 69
fannkuchredux 5 52 5 58 50 97 50 107
fluentd 5 63 5 62 50 26 50 24
graphql 5 85 5 86 50 58 50 51
graphql-native 5 40 5 56 50 10 50 18
lee 5 23 5 24 50 10 50 10
matmul 5 51 5 53 50 88 50 97
nbody 5 249 5 252 50 585 50 687
nqueens 5 120 5 122 50 75 50 555
optcarrot 5 10 5 10 50 10 50 10
protoboeuf 5 172 5 190 50 620 50 751
protoboeuf-encode 5 179 5 198 50 327 50 783
rack 5 582 5 629 50 956 50 1065
ruby-json 5 83 5 84 50 50 50 50
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 159
tinygql 5 36 5 38 50 22 50 32
30k_ifelse 5 28 5 27 50 216 50 185
30k_methods 5 39 5 38 50 473 50 477
cfunc_itself 5 358 5 358 50 1146 50 1258
fib 5 126 5 120 50 902 50 930
getivar 5 213 5 307 50 2251 50 2401
keyword_args 5 104 5 112 50 1041 50 1242
loops-times 5 24 5 27 50 47 50 62
object-new 5 322 5 351 50 405 50 579
respond_to 5 133 5 132 50 3255 50 3895
ruby-xor 5 245 5 249 50 800 50 1295
setivar 5 361 5 601 50 3193 50 5091
setivar_object 5 354 5 442 50 670 50 691
setivar_young 5 369 5 442 50 702 50 714
str_concat 5 397 5 459 50 983 50 1123
throw 5 1267 5 1310 50 1734 50 1748

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) 1522481 1308695 206 2590 0 0% 0 0 75.167301
chunky-png (click) 335755 285829 74 1322 1 0% 0 0 38.990933
erubi-rails (click) 1962068 1743858 263 3633 21 0% 0 0 107.757332
hexapdf (click) 1490452 1342645 593 15613 40 0% 0 0 452.394862
liquid-c (click) 505485 502784 114 2217 5 0% 0 0 62.077587
liquid-compile (click) 459721 409877 146 2725 2 0% 0 0 83.040137
liquid-render (click) 641748 571675 131 2933 8 0% 0 0 82.495062
lobsters (click) 8523649 7406309 3171 63820 118 0% 0 0 2150.47513
mail (click) 825535 758256 342 7227 40 0% 0 0 205.583373
psych-load (click) 294475 260211 61 825 3 0% 0 0 24.483159
railsbench (click) 3399296 2960669 1653 20193 56 0% 0 0 581.194285
rubocop (click) 5896049 4891701 2885 61743 113 0% 4 0 1922.843012
ruby-lsp (click) 856101 761656 305 5949 29 0% 0 0 163.208848
sequel (click) 478306 419011 11 116 0 0% 0 0 4.024534
binarytrees (click) 7273 6911 6 64 0 0% 0 0 2.593237
blurhash (click) 52289 51444 27 603 0 0% 0 0 18.301879
erubi (click) 269835 226997 5 125 0 0% 0 0 3.908329
etanni (click) 30806 32125 8 108 0 0% 0 0 3.527364
fannkuchredux (click) 24746 40953 3 399 0 0% 0 0 11.12444
fluentd (click) 393712 330525 7 115 0 0% 0 0 3.819333
graphql (click) 459755 389827 66 1035 0 0% 0 0 28.520745
graphql-native (click) 397299 342362 37 399 0 0% 0 0 11.879514
lee (click) 320603 270695 45 1012 0 0% 0 0 30.839632
matmul (click) 11125 4603 8 132 0 0% 0 0 4.257126
nbody (click) 13890 20235 6 238 0 0% 0 0 5.803731
nqueens (click) 22652 36960 5 387 0 0% 0 0 10.363935
optcarrot (click) 325946 290644 188 4740 34 0% 0 0 115.002765
protoboeuf (click) 170142 177773 12 2836 0 0% 0 0 75.762991
protoboeuf-encode (click) 243031 283791 14 1815 0 0% 0 0 47.152175
rack (click) 254665 201891 31 496 0 0% 0 0 13.62915
ruby-json (click) 24634 22156 8 204 0 0% 0 0 5.888706
rubyboy (click) 696795 595850 177 6963 40 0% 0 0 179.473806
rubykon (click) 145853 169867 137 2066 3 0% 0 0 57.519638
sudoku (click) 52157 66291 7 871 0 0% 0 0 24.15357
tinygql (click) 282058 278298 58 977 5 0% 0 0 27.489757
30k_ifelse (click) 6219958 5057296 9259 75432 0 0% 0 0 1967.388681
30k_methods (click) 2234566 1592952 5778 19357 0 0% 0 0 489.805621
cfunc_itself (click) 5127 4155 4 53 0 0% 0 0 1.483116
fib (click) 2659 2995 3 30 0 0% 0 0 1.06259
getivar (click) 3812 6802 3 78 0 0% 0 0 1.925497
keyword_args (click) 6332 4965 5 56 0 0% 0 0 1.783636
loops-times (click) 6972 8013 5 93 0 0% 0 0 2.729988
object-new (click) 2406 2818 2 36 0 0% 0 0 1.102867
respond_to (click) 6451 6819 4 80 0 0% 0 0 2.089263
ruby-xor (click) 5876 8690 4 100 0 0% 0 0 2.697022
setivar (click) 2783 3726 3 46 0 0% 0 0 1.219295
setivar_object (click) 3402 3956 3 49 0 0% 0 0 1.409721
setivar_young (click) 4297 4867 4 63 0 0% 0 0 1.691827
str_concat (click) 5799 6969 6 82 0 0% 0 0 2.486365
throw (click) 5953 4624 5 53 0 0% 0 0 1.813284

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.