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.

binary-trees
source secs mem gz busy cpu load
Ruby 44.61 531,600 1096 125.16 67% 72% 60% 81%
Matz's Ruby 1,268.05 839,888 400 1,281.19 60% 0% 40% 0%
fannkuch-redux
source secs mem gz busy cpu load
Ruby 303.19 26,680 1444 1,169.40 100% 91% 98% 97%
Matz's Ruby 6,692.98 19,320 1444 25,945.29 97% 99% 97% 96%
mandelbrot
source secs mem gz busy cpu load
Ruby 335.33 66,188 931 1,339.92 100% 100% 100% 100%
Matz's Ruby 4,299.88 68,672 931 17,193.33 100% 100% 100% 100%
n-body
source secs mem gz busy cpu load
Ruby 374.51 25,668 1137 387.63 67% 20% 2% 14%
Matz's Ruby 4,386.74 4,084 1137 4,426.81 65% 0% 0% 35%
fasta
source secs mem gz busy cpu load
Ruby 51.74 123,240 1069 55.08 43% 44% 2% 17%
Matz's Ruby 477.60 101,796 1020 486.43 13% 85% 0% 3%
pidigits
source secs mem gz busy cpu load
Ruby 3.23 380,036 485 4.90 12% 50% 52% 37%
Matz's Ruby 29.43 18,384 518 29.65 100% 0% 0% 0%
spectral-norm
source secs mem gz busy cpu load
Ruby 150.32 26,188 839 585.35 97% 97% 97% 97%
Matz's Ruby 973.55 21,068 839 3,842.21 99% 98% 99% 99%
k-nucleotide
source secs mem gz busy cpu load
Ruby 103.71 400,128 859 377.05 95% 85% 95% 89%
Matz's Ruby 314.56 127,080 644 1,036.20 93% 81% 82% 73%
reverse-complement
source secs mem gz busy cpu load
Ruby 20.99 1,611,616 295 27.84 98% 7% 18% 9%
Matz's Ruby 38.45 492,804 264 38.84 100% 0% 1% 0%
regex-redux
source secs mem gz busy cpu load
Ruby 15.97 277,888 726 33.81 41% 76% 59% 36%
Matz's Ruby   Bad Output
Ruby

ruby 2.7.0p0 (2019-12-25 revision 647ee6f091) [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