The Computer Language
Benchmarks Game

Ruby versus Matz's Ruby fastest programs

Always look at the source code.

These are only the fastest programs. Look at the other programs. They may seem more-like a fair comparison to you.

fannkuch-redux
source secs mem gz busy cpu load
Ruby 217.08 25,628 1444 843.83 99% 99% 100% 91%
Matz's Ruby 3,599.05 16,720 1444 13,876.93 95% 94% 100% 97%
binary-trees
source secs mem gz busy cpu load
Ruby 22.04 531,952 1096 62.37 68% 89% 64% 62%
Matz's Ruby 310.83 1,413,528 1096 984.39 72% 73% 71% 100%
n-body
source secs mem gz busy cpu load
Ruby 246.88 22,032 1137 253.92 0% 1% 1% 100%
Matz's Ruby 2,293.99 3,952 1137 4,696.44 78% 12% 75% 40%
fasta
source secs mem gz busy cpu load
Ruby 30.87 71,464 1069 32.72 2% 2% 100% 3%
Matz's Ruby 253.47 101,720 1071 256.95 1% 100% 0% 0%
spectral-norm
source secs mem gz busy cpu load
Ruby 99.44 25,108 839 379.49 96% 95% 95% 95%
Matz's Ruby 411.31 4,400 292 825.97 0% 100% 10% 90%
k-nucleotide
source secs mem gz busy cpu load
Ruby 68.79 399,736 859 240.00 96% 80% 82% 91%
Matz's Ruby 179.62 126,924 644 589.76 95% 69% 67% 98%
reverse-complement
source secs mem gz busy cpu load
Ruby 9.20 2,009,456 601 18.23 75% 42% 43% 38%
Matz's Ruby 21.41 492,788 264 43.01 1% 100% 0% 100%
regex-redux
source secs mem gz busy cpu load
Ruby 9.49 277,372 724 20.85 90% 43% 38% 49%
Matz's Ruby 16.43 221,312 724 48.13 100% 100% 47% 47%
mandelbrot
source secs mem gz busy cpu load
Ruby 235.78 59,064 931 942.08 100% 100% 100% 100%
Matz's Ruby 133.76 33,612 918 513.86 96% 96% 96% 96%
pidigits
source secs mem gz busy cpu load
Ruby 1.41 303,640 485 2.50 39% 30% 10% 99%
Matz's Ruby   Failed
Ruby

ruby 2.7.1p83 (2020-03-31 revision a0c7c23c9c) [x86_64-linux]
--jit

Matz's Ruby

ruby 1.8.7 (2008-08-11 patchlevel 72) [x86_64-linux]
 
So old that I haven't been able to get rubygems to work
no backport, no gmp