The Computer Language
Benchmarks Game

Node.js programs versus Ruby

by benchmark task performance

mandelbrot
source secs mem gz cpu cpu load
Node.js 17.72 613,608 748 63.70 85% 94% 99% 83%
Ruby 520.83 127,152 925 2,081.07 100% 100% 100% 100%
n-body
source secs mem gz cpu cpu load
Node.js 26.61 33,152 1297 26.61 100% 0% 0% 1%
Ruby 641.41 8,848 1137 641.26 8% 93% 0% 0%
fasta
source secs mem gz cpu cpu load
Node.js 9.80 34,804 1785 9.82 100% 1% 0% 0%
Ruby 99.67 106,544 1002 99.65 0% 0% 100% 0%
spectral-norm
source secs mem gz cpu cpu load
Node.js 15.79 31,900 381 15.79 100% 1% 0% 0%
Ruby 119.33 49,312 835 461.61 97% 97% 97% 97%
fannkuch-redux
source secs mem gz cpu cpu load
Node.js 89.63 30,960 473 89.61 0% 100% 0% 1%
Ruby 671.17 30,416 1432 2,613.66 98% 100% 100% 92%
regex-redux
source secs mem gz cpu cpu load
Node.js 4.22 596,420 432 4.24 100% 0% 0% 1%
Ruby 25.64 311,964 431 25.63 6% 4% 60% 31%
k-nucleotide
source secs mem gz cpu cpu load
Node.js 61.24 1,739,992 935 137.09 80% 75% 95% 71%
Ruby 95.27 381,212 858 342.07 97% 86% 86% 91%
binary-trees
source secs mem gz cpu cpu load
Node.js 45.39 658,324 440 81.91 37% 39% 59% 46%
Ruby 47.66 511,724 1083 137.38 66% 90% 70% 63%
reverse-complement
source secs mem gz cpu cpu load
Node.js 4.14 243,736 1103 4.40 26% 21% 7% 53%
Ruby 3.73 571,404 517 7.00 49% 34% 96% 10%
pidigits
source secs mem gz cpu cpu load
Node.js   Bad Output
Ruby 0.23 704 485 0.21 5% 0% 95% 4%
Node.js

v9.4.0

Ruby

ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-linux]