The Computer Language
Benchmarks Game

Ruby versus Matz's Ruby fastest programs

Always look at the source code.

These are only the fastest programs. Do some of them use manually vectorized SIMD? 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 181.72 26,276 1455 716.75 99% 100% 99% 96%
Matz's Ruby 3,668.48 17,512 1455 14,149.20 95% 96% 98% 98%
binary-trees
source secs mem gz busy cpu load
Ruby 23.80 566,560 1008 67.07 58% 96% 63% 64%
Matz's Ruby 316.78 1,413,456 1008 997.03 73% 72% 75% 95%
fasta
source secs mem gz busy cpu load
Ruby 25.63 120,804 1069 28.41 0% 10% 100% 1%
Matz's Ruby 265.46 101,572 1020 268.48 0% 0% 23% 78%
n-body
source secs mem gz busy cpu load
Ruby 232.08 22,968 1137 236.00 0% 1% 100% 0%
Matz's Ruby 2,280.53 3,816 1137 2,298.53 0% 0% 0% 100%
mandelbrot
source secs mem gz busy cpu load
Ruby 262.79 69,328 880 1,049.78 100% 100% 100% 100%
Matz's Ruby 1,961.35 53,240 970 7,844.90 100% 100% 100% 100%
spectral-norm
source secs mem gz busy cpu load
Ruby 118.16 24,764 326 120.08 0% 1% 100% 0%
Matz's Ruby 547.06 19,728 758 2,056.03 93% 95% 94% 94%
k-nucleotide
source secs mem gz busy cpu load
Ruby 77.22 146,188 576 271.55 81% 84% 93% 93%
Matz's Ruby 174.82 126,732 576 573.54 69% 83% 86% 90%
reverse-complement
source secs mem gz busy cpu load
Ruby 11.45 2,009,880 482 21.50 34% 70% 57% 26%
Matz's Ruby 21.02 492,816 264 21.29 1% 0% 100% 0%
regex-redux
source secs mem gz busy cpu load
Ruby 9.66 277,900 724 21.43 44% 96% 38% 43%
Matz's Ruby 15.83 223,648 724 36.10 94% 44% 44% 46%
pidigits
source secs mem gz busy cpu load
Ruby 2.17 545,520 485 4.34 27% 1% 71% 100%
Matz's Ruby   Failed
Ruby

ruby 3.0.0p0 (2020-12-25 revision 95aff21468) [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