YJIT Benchmarks

Details for Benchmarks at 2024-01-16 19:08:16 UTC

YJIT metrics from the yjit-bench suite using Ruby d124124c16

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 64.5% faster than CRuby 3.4.0dev
On railsbench it is
  • 67.2% 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 480 30 480
chunky-png 30 30 30 30
erubi-rails 30 15 30 15
hexapdf 30 15 30 15
liquid-c 30 347 30 347
liquid-compile 30 341 30 341
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 390 30 390
sequel 30 302 30 302
binarytrees 30 85 30 85
erubi 30 78 30 78
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 16 30 16
nbody 30 275 30 275
nqueens 30 264 30 264
optcarrot 30 15 30 15
rack 30 177 30 177
ruby-json 30 15 30 15
rubykon 30 15 30 15
sudoku 30 24 30 24
tinygql 30 42 30 42
30k_ifelse 30 55 30 55
30k_methods 30 23 30 23
cfunc_itself 30 827 30 827
fib 30 416 30 416
getivar 30 936 30 936
keyword_args 30 533 30 533
respond_to 30 1436 30 1436
setivar 30 1668 30 1668
setivar_object 30 472 30 472
setivar_young 30 471 30 471
str_concat 30 447 30 447
throw 30 841 30 841

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) 734862 634597 50 516 3 0% 0 0 0 15.465571
chunky-png (click) 306052 276549 87 1098 1 0% 0 0 0 32.918016
erubi-rails (click) 1610622 1399416 287 2923 1 0% 0 0 0 83.135598
hexapdf (click) 1331246 1150311 598 12101 36 0% 0 0 0 354.080211
liquid-c (click) 485829 435749 120 1702 5 0% 0 0 0 47.277275
liquid-compile (click) 348553 324632 150 2018 2 0% 0 0 0 61.850321
liquid-render (click) 516824 467271 143 2162 5 0% 0 0 0 60.060442
lobsters (click) 7404803 6395122 3181 48239 64 0% 0 0 0 1612.98656
mail (click) 680874 626902 345 4763 12 0% 0 0 0 139.724889
psych-load (click) 261160 236432 65 603 3 0% 0 0 0 19.004446
railsbench (click) 2457788 2199352 1357 12393 16 0% 0 0 0 362.768535
ruby-lsp (click) 5294275 4498752 3394 49721 398 0% 4 0 0 1519.164789
sequel (click) 458422 409609 16 118 0 0% 0 0 0 4.261865
binarytrees (click) 9306 8120 11 75 0 0% 0 0 0 2.913817
erubi (click) 232843 229188 10 97 0 0% 0 0 0 3.326323
etanni (click) 32254 22475 12 92 0 0% 0 0 0 3.123931
fannkuchredux (click) 22749 23446 9 235 0 0% 0 0 0 7.147064
fluentd (click) 331887 315054 12 104 0 0% 0 0 0 3.36558
graphql (click) 396715 350586 70 657 0 0% 0 0 0 20.230398
graphql-native (click) 362582 319325 42 263 0 0% 0 0 0 8.729326
lee (click) 281047 266436 49 691 0 0% 0 0 0 21.828665
matmul (click) 12919 12854 12 124 0 0% 0 0 0 4.180453
nbody (click) 18474 17501 11 191 0 0% 0 0 0 5.590308
nqueens (click) 19862 5821 10 208 0 0% 0 0 0 6.507093
optcarrot (click) 314635 260135 194 4244 32 0% 0 0 0 100.773929
rack (click) 239109 214436 31 306 0 0% 0 0 0 8.884346
ruby-json (click) 27979 25354 12 205 0 0% 0 0 0 6.246375
rubykon (click) 128522 101675 144 1470 3 0% 0 0 0 41.302128
sudoku (click) 46943 31883 10 515 0 0% 0 0 0 15.473905
tinygql (click) 277062 244647 63 772 5 0% 0 0 0 22.068987
30k_ifelse (click) 4909835 4375023 9264 50819 0 0% 0 0 0 1379.138358
30k_methods (click) 1850542 1594540 5782 19373 0 0% 0 0 0 490.451706
cfunc_itself (click) 7728 6775 9 72 0 0% 0 0 0 2.344145
fib (click) 5044 5012 8 49 0 0% 0 0 0 1.768989
getivar (click) 6179 6402 8 74 0 0% 0 0 0 2.211267
keyword_args (click) 8341 6984 10 74 0 0% 0 0 0 2.493934
respond_to (click) 8471 8395 9 87 0 0% 0 0 0 2.733315
setivar (click) 5330 4983 8 54 0 0% 0 0 0 1.793188
setivar_object (click) 5668 5003 8 54 0 0% 0 0 0 1.840304
setivar_young (click) 6435 5792 9 62 0 0% 0 0 0 2.068711
str_concat (click) 8275 7972 11 89 0 0% 0 0 0 2.842199
throw (click) 7723 6444 10 69 0 0% 0 0 0 2.32366

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.