YJIT Benchmarks

Details for Benchmarks at 2024-02-17 06:08:14 UTC

YJIT metrics from the yjit-bench suite using Ruby b56b8ec797

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 69.2% faster than CRuby 3.4.0dev
On railsbench it is
  • 71.5% 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 510 30 510
chunky-png 30 31 30 31
erubi-rails 30 19 30 19
hexapdf 30 15 30 15
liquid-c 30 350 30 350
liquid-compile 30 335 30 335
liquid-render 30 251 30 251
lobsters 30 23 30 23
mail 30 164 30 164
psych-load 30 15 30 15
railsbench 30 15 30 15
rubocop 30 183 30 183
ruby-lsp 30 180 30 180
sequel 30 289 30 289
binarytrees 30 85 30 85
blurhash 30 102 30 102
erubi 30 75 30 75
etanni 30 51 30 51
fannkuchredux 30 24 30 24
fluentd 30 15 30 15
graphql 30 15 30 15
graphql-native 30 22 30 22
lee 30 20 30 20
matmul 30 18 30 18
nbody 30 339 30 339
nqueens 30 301 30 301
optcarrot 30 15 30 15
rack 30 175 30 175
ruby-json 30 15 30 15
rubykon 30 15 30 15
sudoku 30 26 30 26
tinygql 30 40 30 40
30k_ifelse 30 55 30 55
30k_methods 30 23 30 23
cfunc_itself 30 826 30 826
fib 30 416 30 416
getivar 30 927 30 927
keyword_args 30 531 30 531
respond_to 30 1457 30 1457
ruby-xor 30 104 30 104
setivar 30 2393 30 2393
setivar_object 30 366 30 366
setivar_young 30 392 30 392
str_concat 30 415 30 415
throw 30 852 30 852

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) 884230 753423 49 522 0 0% 0 0 15.975645
chunky-png (click) 323937 285708 87 1095 1 0% 0 0 31.900526
erubi-rails (click) 1716949 1431623 280 2905 6 0% 0 0 80.764344
hexapdf (click) 1404388 1159720 596 12597 37 0% 0 0 367.54744
liquid-c (click) 519586 455854 120 1758 5 0% 0 0 47.743888
liquid-compile (click) 442437 397510 151 2055 2 0% 0 0 61.867253
liquid-render (click) 620353 557264 144 2274 8 0% 0 0 62.438568
lobsters (click) 7878260 6590189 3219 49981 73 0% 0 0 1698.039994
mail (click) 729282 603790 346 4849 14 0% 0 0 141.885021
psych-load (click) 296650 261563 65 652 3 0% 0 0 20.046177
railsbench (click) 3008542 2586396 1643 15660 54 0% 0 0 450.025241
rubocop (click) 5357958 4615597 2902 47705 106 0% 4 0 1419.549989
ruby-lsp (click) 634798 554482 159 2816 14 0% 0 0 78.279673
sequel (click) 494094 421283 16 119 0 0% 0 0 4.463782
binarytrees (click) 9392 7588 11 75 0 0% 0 0 2.985221
blurhash (click) 52663 47827 32 476 0 0% 0 0 15.583448
erubi (click) 258521 217483 10 114 0 0% 0 0 3.817125
etanni (click) 31784 27950 12 98 0 0% 0 0 3.25857
fannkuchredux (click) 24986 25976 9 259 0 0% 0 0 7.807301
fluentd (click) 386575 313144 11 111 0 0% 0 0 3.738554
graphql (click) 440710 366717 70 676 0 0% 0 0 20.149922
graphql-native (click) 406267 344452 41 274 0 0% 0 0 8.886924
lee (click) 313027 278534 49 737 0 0% 0 0 23.015866
matmul (click) 12586 12175 12 126 0 0% 0 0 4.227712
nbody (click) 15177 7657 11 187 0 0% 0 0 4.91775
nqueens (click) 23683 17949 10 263 0 0% 0 0 7.662832
optcarrot (click) 317208 278543 192 4345 34 0% 0 0 103.839301
rack (click) 269159 234972 31 322 0 0% 0 0 9.028426
ruby-json (click) 28209 23153 12 200 0 0% 0 0 5.784982
rubykon (click) 135969 124825 143 1520 3 0% 0 0 42.230267
sudoku (click) 47007 45195 11 507 0 0% 0 0 15.26695
tinygql (click) 310058 258501 63 791 5 0% 0 0 22.964851
30k_ifelse (click) 5222671 4374319 9264 50815 0 0% 0 0 1464.350489
30k_methods (click) 2019688 1594135 5782 19371 0 0% 0 0 520.761769
cfunc_itself (click) 7663 5893 9 72 0 0% 0 0 2.272642
fib (click) 5017 4633 8 49 0 0% 0 0 1.733535
getivar (click) 6102 6023 8 74 0 0% 0 0 2.247336
keyword_args (click) 8546 6585 10 74 0 0% 0 0 2.548898
respond_to (click) 8415 7843 9 87 0 0% 0 0 2.702961
ruby-xor (click) 8142 7087 9 87 0 0% 0 0 2.642722
setivar (click) 5193 4604 8 54 0 0% 0 0 1.792756
setivar_object (click) 5561 4624 8 54 0 0% 0 0 1.800189
setivar_young (click) 6284 5274 9 62 0 0% 0 0 2.030881
str_concat (click) 8006 7287 11 87 0 0% 0 0 2.936521
throw (click) 7946 6065 10 69 0 0% 0 0 2.356156

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.