YJIT Benchmarks

Details for Benchmarks at 2024-02-07 19:08:17 UTC

YJIT metrics from the yjit-bench suite using Ruby a5c871e201

Using the geomean of the headline benchmarks for x86 YJIT 3.4.0dev is
  • 68.1% faster than CRuby 3.4.0dev
On railsbench it is
  • 75.3% 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 483 30 483
chunky-png 30 30 30 30
erubi-rails 30 19 30 19
hexapdf 30 15 30 15
liquid-c 30 349 30 349
liquid-compile 30 335 30 335
liquid-render 30 247 30 247
lobsters 30 22 30 22
mail 30 162 30 162
psych-load 30 15 30 15
railsbench 30 15 30 15
rubocop 30 177 30 177
ruby-lsp 30 211 30 211
sequel 30 290 30 290
binarytrees 30 83 30 83
blurhash 30 102 30 102
erubi 30 75 30 75
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 18 30 18
nbody 30 328 30 328
nqueens 30 301 30 301
optcarrot 30 15 30 15
rack 30 178 30 178
ruby-json 30 15 30 15
rubykon 30 15 30 15
sudoku 30 25 30 25
tinygql 30 41 30 41
30k_ifelse 30 55 30 55
30k_methods 30 24 30 24
cfunc_itself 30 827 30 827
fib 30 416 30 416
getivar 30 943 30 943
keyword_args 30 533 30 533
respond_to 30 1439 30 1439
ruby-xor 30 93 30 93
setivar 30 1668 30 1668
setivar_object 30 294 30 294
setivar_young 30 354 30 354
str_concat 30 397 30 397
throw 30 831 30 831

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) 853973 766575 49 537 0 0% 0 0 0 15.996461
chunky-png (click) 321567 296192 87 1104 1 0% 0 0 0 32.794835
erubi-rails (click) 1663919 1463514 280 2897 6 0% 0 0 0 81.966582
hexapdf (click) 1363085 1151623 596 12413 37 0% 0 0 0 366.459242
liquid-c (click) 498217 423869 119 1762 5 0% 0 0 0 48.727198
liquid-compile (click) 427763 382900 151 2055 2 0% 0 0 0 63.24526
liquid-render (click) 602941 524421 143 2269 8 0% 0 0 0 63.56948
lobsters (click) 7554196 6468591 3225 50149 72 0% 0 0 0 1691.588653
mail (click) 702577 635663 345 4833 14 0% 0 0 0 142.374571
psych-load (click) 284223 255822 65 649 3 0% 0 0 0 20.286892
railsbench (click) 2910055 2524200 1642 15561 54 0% 0 0 0 447.5271
rubocop (click) 4956439 4334508 2901 44385 100 0% 4 0 0 1347.780611
ruby-lsp (click) 618824 574442 159 2792 14 0% 0 0 0 79.13528
sequel (click) 475140 404692 16 120 0 0% 0 0 0 4.696548
binarytrees (click) 9143 8108 11 75 0 0% 0 0 0 2.997397
blurhash (click) 51449 50179 32 478 0 0% 0 0 0 15.731416
erubi (click) 257320 240469 10 114 0 0% 0 0 0 3.851949
etanni (click) 31551 30158 12 98 0 0% 0 0 0 3.341051
fannkuchredux (click) 24892 26732 9 259 0 0% 0 0 0 8.024288
fluentd (click) 371258 312206 11 111 0 0% 0 0 0 3.797905
graphql (click) 422721 350416 70 668 0 0% 0 0 0 20.866864
graphql-native (click) 389168 344228 42 273 0 0% 0 0 0 9.102086
lee (click) 300568 257487 49 734 0 0% 0 0 0 23.282181
matmul (click) 12467 4614 12 126 0 0% 0 0 0 4.2947
nbody (click) 15120 16376 11 187 0 0% 0 0 0 5.105761
nqueens (click) 23567 27084 10 263 0 0% 0 0 0 7.854453
optcarrot (click) 312040 304710 194 4321 34 0% 0 0 0 103.407242
rack (click) 257571 237062 31 322 0 0% 0 0 0 9.13483
ruby-json (click) 27898 25598 12 202 0 0% 0 0 0 6.177084
rubykon (click) 131010 79614 145 1502 3 0% 0 0 0 42.358164
sudoku (click) 46746 38099 11 507 0 0% 0 0 0 15.491762
tinygql (click) 295757 251328 63 792 5 0% 0 0 0 22.7069
30k_ifelse (click) 4909290 4374633 9264 50815 0 0% 0 0 0 1415.457023
30k_methods (click) 1850186 1594311 5782 19371 0 0% 0 0 0 500.210031
cfunc_itself (click) 7580 6763 9 72 0 0% 0 0 0 2.370797
fib (click) 4896 5000 8 49 0 0% 0 0 0 1.835205
getivar (click) 6031 6390 8 74 0 0% 0 0 0 2.285115
keyword_args (click) 8193 6972 10 74 0 0% 0 0 0 2.588317
respond_to (click) 8323 191 9 87 0 0% 0 0 0 2.7997
ruby-xor (click) 7503 7326 9 81 0 0% 0 0 0 2.651956
setivar (click) 5182 4971 8 54 0 0% 0 0 0 1.892234
setivar_object (click) 5520 4991 8 54 0 0% 0 0 0 1.951141
setivar_young (click) 6287 5780 9 62 0 0% 0 0 0 2.124958
str_concat (click) 7845 7725 11 87 0 0% 0 0 0 2.972391
throw (click) 7575 6432 10 69 0 0% 0 0 0 2.399756

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.