YJIT Benchmarks

Details for Benchmarks at 2024-04-30 06:08:14 UTC

YJIT metrics from the yjit-bench suite using Ruby 431711a8bb

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 72.0% faster than CRuby 3.4.0dev
On railsbench it is
  • 78.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 509 30 509
chunky-png 30 31 30 31
erubi-rails 30 19 30 19
hexapdf 30 15 30 15
liquid-c 30 342 30 342
liquid-compile 30 355 30 355
liquid-render 30 246 30 246
lobsters 30 22 30 22
mail 30 160 30 160
psych-load 30 15 30 15
railsbench 30 15 30 15
rubocop 30 181 30 181
ruby-lsp 30 179 30 179
sequel 30 285 30 285
binarytrees 30 87 30 87
blurhash 30 101 30 101
erubi 30 77 30 77
etanni 30 24 30 24
fannkuchredux 30 25 30 25
fluentd 30 15 30 15
graphql 30 15 30 15
graphql-native 30 33 30 33
lee 30 19 30 19
matmul 30 17 30 17
nbody 30 319 30 319
nqueens 30 313 30 313
optcarrot 30 15 30 15
protoboeuf 30 459 30 459
rack 30 182 30 182
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 827 30 827
fib 30 418 30 418
getivar 30 1013 30 1013
keyword_args 30 646 30 646
respond_to 30 1462 30 1462
ruby-xor 30 103 30 103
setivar 30 2546 30 2546
setivar_object 30 529 30 529
setivar_young 30 536 30 536
str_concat 30 426 30 426
throw 30 777 30 777

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) 880992 736233 49 526 0 0% 0 0 17.135795
chunky-png (click) 333830 274394 87 1094 1 0% 0 0 32.825046
erubi-rails (click) 1684142 1477766 276 2937 6 0% 0 0 83.674877
hexapdf (click) 1407055 1281692 597 12718 41 0% 0 0 377.183224
liquid-c (click) 516657 396064 119 1757 5 0% 0 0 49.620942
liquid-compile (click) 441440 377234 151 2077 2 0% 0 0 64.738093
liquid-render (click) 614846 517207 136 2292 8 0% 0 0 65.078588
lobsters (click) 7777024 6530126 3213 51147 89 0% 0 0 1738.278101
mail (click) 722468 647319 346 4865 14 0% 0 0 145.702208
psych-load (click) 298119 236054 65 656 3 0% 0 0 20.888592
railsbench (click) 2963149 2485413 1634 15970 57 0% 0 0 467.525977
rubocop (click) 5324077 4592575 2901 48286 112 0% 4 0 1466.899807
ruby-lsp (click) 625316 526554 159 2803 28 0% 0 0 81.087054
sequel (click) 488756 408969 16 116 0 0% 0 0 4.256547
binarytrees (click) 9300 8262 11 75 0 0% 0 0 3.061081
blurhash (click) 50973 43758 32 460 0 0% 0 0 15.969201
erubi (click) 267996 215699 10 112 0 0% 0 0 3.867994
etanni (click) 29692 28216 11 91 0 0% 0 0 3.032031
fannkuchredux (click) 23856 29309 9 257 0 0% 0 0 8.423328
fluentd (click) 382721 332076 11 111 0 0% 0 0 3.817239
graphql (click) 433718 343417 70 685 0 0% 0 0 21.853134
graphql-native (click) 401292 373553 42 278 0 0% 0 0 9.490555
lee (click) 313275 294758 49 737 0 0% 0 0 23.941848
matmul (click) 12453 4981 12 126 0 0% 0 0 4.46523
nbody (click) 14798 17933 11 185 0 0% 0 0 5.232487
nqueens (click) 22703 29059 10 260 0 0% 0 0 8.060788
optcarrot (click) 311581 267827 192 4326 34 0% 0 0 104.706398
protoboeuf (click) 148013 144784 17 1378 0 0% 0 0 42.939139
rack (click) 269907 197952 31 326 0 0% 0 0 9.567063
ruby-json (click) 32870 30395 12 196 0 0% 0 0 6.036712
rubykon (click) 131218 132129 143 1501 3 0% 0 0 43.383815
sudoku (click) 45463 61097 11 507 0 0% 0 0 16.040156
tinygql (click) 310436 265203 63 787 5 0% 0 0 23.354577
30k_ifelse (click) 5137861 4732461 9264 50813 0 0% 0 0 1524.314962
30k_methods (click) 2019563 1594382 5782 19369 0 0% 0 0 519.520768
cfunc_itself (click) 7534 6180 9 70 0 0% 0 0 2.385078
fib (click) 4970 5003 8 49 0 0% 0 0 2.008658
getivar (click) 5963 6375 8 74 0 0% 0 0 2.584456
keyword_args (click) 8409 6912 10 72 0 0% 0 0 2.746868
respond_to (click) 8277 8274 9 85 0 0% 0 0 2.873327
ruby-xor (click) 7891 7863 9 87 0 0% 0 0 2.889476
setivar (click) 5102 5375 8 54 0 0% 0 0 2.127347
setivar_object (click) 5470 5395 8 54 0 0% 0 0 2.380201
setivar_young (click) 6182 6093 9 62 0 0% 0 0 2.445444
str_concat (click) 7774 7946 11 85 0 0% 0 0 2.993951
throw (click) 7895 6377 10 69 0 0% 0 0 2.445184

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.