YJIT Benchmarks

Details for Benchmarks at 2024-04-28 06:31:35 UTC

YJIT metrics from the yjit-bench suite using Ruby 5c3d5c7cdd

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 69.6% faster than CRuby 3.4.0dev
On railsbench it is
  • 78.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 490 30 490
chunky-png 30 32 30 32
erubi-rails 30 20 30 20
hexapdf 30 15 30 15
liquid-c 30 343 30 343
liquid-compile 30 341 30 341
liquid-render 30 247 30 247
lobsters 30 22 30 22
mail 30 160 30 160
psych-load 30 15 30 15
railsbench 30 15 30 15
rubocop 30 180 30 180
ruby-lsp 30 169 30 169
sequel 30 286 30 286
binarytrees 30 88 30 88
blurhash 30 102 30 102
erubi 30 76 30 76
etanni 30 24 30 24
fannkuchredux 30 24 30 24
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 334 30 334
nqueens 30 301 30 301
optcarrot 30 15 30 15
protoboeuf 30 406 30 406
rack 30 178 30 178
ruby-json 30 15 30 15
rubykon 30 15 30 15
sudoku 30 25 30 25
tinygql 30 39 30 39
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 109 30 109
setivar 30 2546 30 2546
setivar_object 30 415 30 415
setivar_young 30 431 30 431
str_concat 30 424 30 424
throw 30 781 30 781

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) 881754 760970 49 528 0 0% 0 0 16.25429
chunky-png (click) 333979 274395 87 1094 1 0% 0 0 33.076128
erubi-rails (click) 1686259 1495614 277 2948 6 0% 0 0 84.094419
hexapdf (click) 1407183 1142480 598 12720 41 0% 0 0 378.709444
liquid-c (click) 516808 453364 119 1754 5 0% 0 0 49.77015
liquid-compile (click) 442079 377715 151 2084 2 0% 0 0 65.482126
liquid-render (click) 615301 541938 136 2294 8 0% 0 0 64.734287
lobsters (click) 7807975 6544596 3211 51217 89 0% 0 0 1743.530493
mail (click) 722587 630991 346 4865 14 0% 0 0 146.684717
psych-load (click) 298270 277006 65 656 3 0% 0 0 20.757656
railsbench (click) 2962558 2474793 1634 15935 57 0% 0 0 464.480851
rubocop (click) 5320995 4646186 2901 48247 109 0% 4 0 1468.968517
ruby-lsp (click) 625493 502148 159 2803 28 0% 0 0 79.093064
sequel (click) 489090 425094 16 117 0 0% 0 0 4.356511
binarytrees (click) 9300 8262 11 75 0 0% 0 0 3.06854
blurhash (click) 50973 43758 32 460 0 0% 0 0 15.943461
erubi (click) 268015 240244 10 112 0 0% 0 0 3.927898
etanni (click) 29692 28216 11 91 0 0% 0 0 2.993012
fannkuchredux (click) 23856 29309 9 257 0 0% 0 0 8.51193
fluentd (click) 382136 331471 11 111 0 0% 0 0 3.86567
graphql (click) 433879 351607 70 685 0 0% 0 0 21.188646
graphql-native (click) 401449 340644 42 278 0 0% 0 0 9.47849
lee (click) 313294 278323 49 737 0 0% 0 0 23.688992
matmul (click) 12453 4981 12 126 0 0% 0 0 4.547887
nbody (click) 14798 17933 11 185 0 0% 0 0 5.280021
nqueens (click) 22703 29059 10 260 0 0% 0 0 8.050576
optcarrot (click) 311581 267827 192 4326 34 0% 0 0 105.125894
protoboeuf (click) 148013 144784 17 1378 0 0% 0 0 42.895937
rack (click) 269664 214009 31 323 0 0% 0 0 9.570544
ruby-json (click) 32870 30395 12 196 0 0% 0 0 5.979064
rubykon (click) 131218 132129 143 1501 3 0% 0 0 43.485994
sudoku (click) 45463 61097 11 507 0 0% 0 0 16.026313
tinygql (click) 310457 273364 63 787 5 0% 0 0 23.291127
30k_ifelse (click) 5137861 4732461 9264 50813 0 0% 0 0 1508.135474
30k_methods (click) 2019563 1594382 5782 19369 0 0% 0 0 519.42296
cfunc_itself (click) 7534 6180 9 70 0 0% 0 0 2.45623
fib (click) 4970 5003 8 49 0 0% 0 0 2.012683
getivar (click) 5963 6375 8 74 0 0% 0 0 2.470693
keyword_args (click) 8409 6912 10 72 0 0% 0 0 2.799759
respond_to (click) 8277 8274 9 85 0 0% 0 0 2.924742
ruby-xor (click) 7891 7863 9 87 0 0% 0 0 2.865991
setivar (click) 5102 5375 8 54 0 0% 0 0 2.112725
setivar_object (click) 5470 5395 8 54 0 0% 0 0 2.397095
setivar_young (click) 6182 6093 9 62 0 0% 0 0 2.616946
str_concat (click) 7774 7946 11 85 0 0% 0 0 3.107933
throw (click) 7895 6377 10 69 0 0% 0 0 2.450666

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.