YJIT Benchmarks

Details for Benchmarks at 2024-02-10 06:08:16 UTC

YJIT metrics from the yjit-bench suite using Ruby 6cafbd35d9

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 66.2% faster than CRuby 3.4.0dev
On railsbench it is
  • 69.4% 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 476 30 476
chunky-png 30 31 30 31
erubi-rails 30 19 30 19
hexapdf 30 15 30 15
liquid-c 30 348 30 348
liquid-compile 30 340 30 340
liquid-render 30 253 30 253
lobsters 30 22 30 22
mail 30 162 30 162
psych-load 30 15 30 15
railsbench 30 15 30 15
rubocop 30 182 30 182
ruby-lsp 30 179 30 179
sequel 30 291 30 291
binarytrees 30 85 30 85
blurhash 30 98 30 98
erubi 30 77 30 77
etanni 30 52 30 52
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 17 30 17
nbody 30 314 30 314
nqueens 30 293 30 293
optcarrot 30 15 30 15
rack 30 182 30 182
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 938 30 938
keyword_args 30 531 30 531
respond_to 30 1460 30 1460
ruby-xor 30 83 30 83
setivar 30 1668 30 1668
setivar_object 30 353 30 353
setivar_young 30 359 30 359
str_concat 30 447 30 447
throw 30 806 30 806

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) 885571 769507 49 522 0 0% 0 0 0 15.428337
chunky-png (click) 336850 293627 87 1104 1 0% 0 0 0 33.017999
erubi-rails (click) 1710920 1443439 280 2964 6 0% 0 0 0 84.905311
hexapdf (click) 1416607 1219805 597 12530 37 0% 0 0 0 371.956641
liquid-c (click) 522767 440270 119 1756 5 0% 0 0 0 48.442743
liquid-compile (click) 445131 381712 151 2055 2 0% 0 0 0 63.242731
liquid-render (click) 623747 541543 143 2267 8 0% 0 0 0 63.458296
lobsters (click) 7867101 6611495 3223 50148 72 0% 0 0 0 1720.91412
mail (click) 734056 613313 345 4850 14 0% 0 0 0 143.88958
psych-load (click) 298548 262005 65 651 3 0% 0 0 0 20.335518
railsbench (click) 2999201 2586163 1642 15588 54 0% 0 0 0 450.987804
rubocop (click) 5373819 4656168 2901 47623 105 0% 4 0 0 1429.115615
ruby-lsp (click) 637893 547001 159 2783 14 0% 0 0 0 78.105563
sequel (click) 493922 422184 16 116 0 0% 0 0 0 4.178131
binarytrees (click) 9392 7588 11 75 0 0% 0 0 0 3.037344
blurhash (click) 52747 47998 32 478 0 0% 0 0 0 15.813238
erubi (click) 269848 231475 10 114 0 0% 0 0 0 3.891722
etanni (click) 31783 27950 12 98 0 0% 0 0 0 3.333508
fannkuchredux (click) 24986 25976 9 259 0 0% 0 0 0 7.873588
fluentd (click) 386895 335624 11 111 0 0% 0 0 0 3.607039
graphql (click) 438793 379803 70 670 0 0% 0 0 0 20.552547
graphql-native (click) 404921 333583 42 273 0 0% 0 0 0 9.131305
lee (click) 311251 261625 49 736 0 0% 0 0 0 23.256232
matmul (click) 12586 12175 12 126 0 0% 0 0 0 4.273871
nbody (click) 15213 7657 11 187 0 0% 0 0 0 5.021488
nqueens (click) 23683 17949 10 263 0 0% 0 0 0 7.868794
optcarrot (click) 320781 237544 194 4347 34 0% 0 0 0 105.267044
rack (click) 270724 235273 31 322 0 0% 0 0 0 9.257979
ruby-json (click) 28230 23153 12 200 0 0% 0 0 0 5.985004
rubykon (click) 134867 98704 145 1504 3 0% 0 0 0 42.204917
sudoku (click) 47007 45195 11 507 0 0% 0 0 0 15.523904
tinygql (click) 311921 258889 63 792 5 0% 0 0 0 23.375431
30k_ifelse (click) 5222688 4374316 9264 50815 0 0% 0 0 0 1470.761651
30k_methods (click) 2019699 1594292 5782 19371 0 0% 0 0 0 524.678882
cfunc_itself (click) 7663 5893 9 72 0 0% 0 0 0 2.285363
fib (click) 5017 4633 8 49 0 0% 0 0 0 1.759951
getivar (click) 6102 6023 8 74 0 0% 0 0 0 2.253088
keyword_args (click) 8526 6585 10 74 0 0% 0 0 0 2.532407
respond_to (click) 8415 7843 9 87 0 0% 0 0 0 2.720168
ruby-xor (click) 7544 6739 9 81 0 0% 0 0 0 2.564176
setivar (click) 5253 4604 8 54 0 0% 0 0 0 1.748806
setivar_object (click) 5591 4624 8 54 0 0% 0 0 0 1.821255
setivar_young (click) 6343 5271 9 62 0 0% 0 0 0 2.024494
str_concat (click) 8006 7287 11 87 0 0% 0 0 0 2.92621
throw (click) 7946 6065 10 69 0 0% 0 0 0 2.354445

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.