YJIT Benchmarks

Details for Benchmarks at 2024-01-23 06:08:14 UTC

YJIT metrics from the yjit-bench suite using Ruby 8c3eb47fff

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 66.4% faster than CRuby 3.4.0dev
On railsbench it is
  • 72.6% 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 486 30 486
chunky-png 30 30 30 30
erubi-rails 30 15 30 15
hexapdf 30 15 30 15
liquid-c 30 354 30 354
liquid-compile 30 355 30 355
liquid-render 30 248 30 248
lobsters 30 23 30 23
mail 30 163 30 163
psych-load 30 15 30 15
railsbench 30 15 30 15
rubocop 30 173 30 173
ruby-lsp 30 176 30 176
sequel 30 298 30 298
binarytrees 30 86 30 86
blurhash 30 88 30 88
erubi 30 75 30 75
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 20 30 20
matmul 30 15 30 15
nbody 30 262 30 262
nqueens 30 76 30 76
optcarrot 30 15 30 15
rack 30 181 30 181
ruby-json 30 15 30 15
rubykon 30 15 30 15
sudoku 30 24 30 24
tinygql 30 41 30 41
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 942 30 942
keyword_args 30 533 30 533
respond_to 30 1437 30 1437
setivar 30 1668 30 1668
setivar_object 30 345 30 345
setivar_young 30 403 30 403
str_concat 30 402 30 402
throw 30 864 30 864

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) 765450 649869 48 521 3 0% 0 0 0 15.47791
chunky-png (click) 315180 301115 87 1076 1 0% 0 0 0 31.577501
erubi-rails (click) 1634318 1453289 287 2909 1 0% 0 0 0 81.93997
hexapdf (click) 1354083 1169482 596 12257 37 0% 0 0 0 360.459408
liquid-c (click) 496659 438528 120 1700 5 0% 0 0 0 46.426692
liquid-compile (click) 423011 380479 151 2030 2 0% 0 0 0 62.253827
liquid-render (click) 591386 540653 143 2188 8 0% 0 0 0 60.731398
lobsters (click) 7609481 6531229 3192 49498 73 0% 0 0 0 1666.030823
mail (click) 693358 605352 345 4769 12 0% 0 0 0 141.366971
psych-load (click) 278157 260958 65 625 3 0% 0 0 0 19.396238
railsbench (click) 2500298 2168950 1367 12726 19 0% 0 0 0 370.73185
rubocop (click) 4887483 4146972 2897 43712 93 0% 4 0 0 1318.595718
ruby-lsp (click) 626204 534105 159 2736 14 0% 0 0 0 76.623865
sequel (click) 467537 402463 16 123 0 0% 0 0 0 5.036466
binarytrees (click) 9291 8120 11 75 0 0% 0 0 0 2.954207
blurhash (click) 51326 46923 32 426 1 0% 0 0 0 14.572361
erubi (click) 251936 213341 10 95 0 0% 0 0 0 3.313849
etanni (click) 30352 20655 12 91 0 0% 0 0 0 3.08531
fannkuchredux (click) 24971 26731 9 259 0 0% 0 0 0 7.928597
fluentd (click) 358423 315907 11 104 0 0% 0 0 0 3.385835
graphql (click) 422547 373485 70 656 0 0% 0 0 0 20.159016
graphql-native (click) 389063 351048 42 261 0 0% 0 0 0 8.665192
lee (click) 294050 261668 49 689 0 0% 0 0 0 21.877368
matmul (click) 12823 4423 12 123 0 0% 0 0 0 4.325988
nbody (click) 18045 16846 11 187 0 0% 0 0 0 5.51772
nqueens (click) 15298 8648 10 160 0 0% 0 0 0 4.981119
optcarrot (click) 303229 236411 197 4239 33 0% 0 0 0 100.154984
rack (click) 251764 217721 31 301 0 0% 0 0 0 8.633274
ruby-json (click) 27348 24919 12 202 0 0% 0 0 0 6.130391
rubykon (click) 127938 92910 144 1464 3 0% 0 0 0 40.909305
sudoku (click) 45221 36695 10 492 0 0% 0 0 0 14.564277
tinygql (click) 290887 249303 63 780 5 0% 0 0 0 22.123802
30k_ifelse (click) 4909438 4374645 9264 50815 0 0% 0 0 0 1388.45547
30k_methods (click) 1850265 1594310 5782 19371 0 0% 0 0 0 494.370722
cfunc_itself (click) 7728 6775 9 72 0 0% 0 0 0 2.484576
fib (click) 5044 5012 8 49 0 0% 0 0 0 1.954835
getivar (click) 6179 6402 8 74 0 0% 0 0 0 2.32569
keyword_args (click) 8341 6984 10 74 0 0% 0 0 0 2.647803
respond_to (click) 8471 8395 9 87 0 0% 0 0 0 2.904257
setivar (click) 5330 4983 8 54 0 0% 0 0 0 1.969131
setivar_object (click) 5668 5003 8 54 0 0% 0 0 0 2.005945
setivar_young (click) 6435 5792 9 62 0 0% 0 0 0 2.266053
str_concat (click) 7993 7737 11 87 0 0% 0 0 0 2.910999
throw (click) 7723 6444 10 69 0 0% 0 0 0 2.397968

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.