YJIT Benchmarks

Details for Benchmarks at 2024-01-13 19:08:14 UTC

YJIT metrics from the yjit-bench suite using Ruby 55335eab80

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 64.9% faster than CRuby 3.4.0dev
On railsbench it is
  • 67.3% faster than CRuby 3.4.0dev

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.4.0dev warmups CRuby 3.4.0dev iters YJIT 3.4.0dev warmups YJIT 3.4.0dev iters
activerecord 30 468 30 468
chunky-png 30 30 30 30
erubi-rails 30 15 30 15
hexapdf 30 15 30 15
liquid-c 30 348 30 348
liquid-compile 30 361 30 361
liquid-render 30 243 30 243
lobsters 30 23 30 23
mail 30 163 30 163
psych-load 30 15 30 15
railsbench 30 15 30 15
ruby-lsp 30 393 30 393
sequel 30 297 30 297
binarytrees 30 83 30 83
erubi 30 76 30 76
etanni 30 51 30 51
fannkuchredux 30 23 30 23
fluentd 30 15 30 15
graphql 30 15 30 15
graphql-native 30 33 30 33
lee 30 19 30 19
matmul 30 15 30 15
nbody 30 280 30 280
nqueens 30 268 30 268
optcarrot 30 15 30 15
rack 30 186 30 186
ruby-json 30 15 30 15
rubykon 30 15 30 15
sudoku 30 25 30 25
tinygql 30 41 30 41
30k_ifelse 30 55 30 55
30k_methods 30 23 30 23
cfunc_itself 30 750 30 750
fib 30 416 30 416
getivar 30 945 30 945
keyword_args 30 495 30 495
respond_to 30 1179 30 1179
setivar 30 1668 30 1668
setivar_object 30 472 30 472
setivar_young 30 470 30 470
str_concat 30 401 30 401
throw 30 833 30 833

Different Ruby configurations want different amounts of warmup. With no JIT, CRuby needs hardly any. YJIT and MJIT 3.0 both warm up quite quickly, while MJIT in 3.1 often slows down for a time as it compiles, after an unpredictable delay.

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) 736214 668178 50 513 3 0% 0 0 0 15.51005
chunky-png (click) 306522 268800 87 1099 1 0% 0 0 0 33.216476
erubi-rails (click) 1610829 1399263 287 2903 1 0% 0 0 0 82.871126
hexapdf (click) 1334559 1161674 598 12124 36 0% 0 0 0 356.87523
liquid-c (click) 486333 452747 120 1701 5 0% 0 0 0 47.332001
liquid-compile (click) 348406 267225 150 2017 2 0% 0 0 0 61.948888
liquid-render (click) 519851 387859 143 2161 5 0% 0 0 0 60.66206
lobsters (click) 7411146 6223031 3182 48274 64 0% 0 0 0 1627.759791
mail (click) 683003 596344 345 4767 12 0% 0 0 0 141.486146
psych-load (click) 260898 211757 65 600 3 0% 0 0 0 18.989253
railsbench (click) 2460447 2169706 1357 12413 16 0% 0 0 0 365.168315
ruby-lsp (click) 5302849 4743638 3394 49739 398 0% 4 0 0 1531.605051
sequel (click) 453682 397112 16 119 0 0% 0 0 0 4.355027
binarytrees (click) 9306 8120 11 75 0 0% 0 0 0 2.925
erubi (click) 232785 229083 10 95 0 0% 0 0 0 3.27976
etanni (click) 32063 22322 12 90 0 0% 0 0 0 3.073555
fannkuchredux (click) 22558 23293 9 233 0 0% 0 0 0 7.22403
fluentd (click) 332235 290801 12 104 0 0% 0 0 0 3.355147
graphql (click) 396988 350781 70 658 0 0% 0 0 0 20.366073
graphql-native (click) 362855 327738 42 264 0 0% 0 0 0 8.793179
lee (click) 281180 250100 49 691 0 0% 0 0 0 22.011178
matmul (click) 12919 12854 12 124 0 0% 0 0 0 4.184912
nbody (click) 18283 17348 11 189 0 0% 0 0 0 5.595168
nqueens (click) 19671 5668 10 206 0 0% 0 0 0 6.476371
optcarrot (click) 314630 260302 194 4242 32 0% 0 0 0 101.387554
rack (click) 239051 198091 31 304 0 0% 0 0 0 8.959754
ruby-json (click) 27788 25201 12 203 0 0% 0 0 0 6.236568
rubykon (click) 130886 112107 144 1491 3 0% 0 0 0 42.235835
sudoku (click) 46943 31883 10 515 0 0% 0 0 0 15.548482
tinygql (click) 277269 244780 63 773 5 0% 0 0 0 22.509249
30k_ifelse (click) 4909644 4374870 9264 50817 0 0% 0 0 0 1393.723771
30k_methods (click) 1850351 1594387 5782 19371 0 0% 0 0 0 496.174359
cfunc_itself (click) 7868 6931 9 73 0 0% 0 0 0 2.394608
fib (click) 5044 5012 8 49 0 0% 0 0 0 1.776263
getivar (click) 6179 6402 8 74 0 0% 0 0 0 2.171904
keyword_args (click) 8481 7140 10 75 0 0% 0 0 0 2.555187
respond_to (click) 8611 8551 9 88 0 0% 0 0 0 2.78165
setivar (click) 5330 4983 8 54 0 0% 0 0 0 1.799686
setivar_object (click) 5668 5003 8 54 0 0% 0 0 0 1.85792
setivar_young (click) 6435 5792 9 62 0 0% 0 0 0 2.104289
str_concat (click) 8079 7814 11 87 0 0% 0 0 0 2.781717
throw (click) 7723 6444 10 69 0 0% 0 0 0 2.332604

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.