/mobile Handheld Friendly website

÷

 1 : Are the Ruby 2.0 programs faster? At a glance.

Each chart bar shows, for one unidentified benchmark, how much the fastest Ruby 2.0 program used compared to the fastest Python 3 program.


These are not the only compilers and interpreters. These are not the only programs that could be written. These are not the only tasks that could be solved. These are just 10 tiny examples.

 2 : Are the Ruby 2.0 programs faster? Approximately.

Each table row shows, for one named benchmark, how much the fastest Ruby 2.0 program used compared to the fastest Python 3 program.

 Ruby 2.0 used what fraction? used how many times more? 
Benchmark Time Memory Code
 spectral-norm1/2±±
 binary-trees1/21/3±
 fasta1/236×±
 n-body±±±
 mandelbrot±1/161/3
 regex-dna±±
 k-nucleotide±1/2±
 fannkuch-redux±±±
 reverse-complement1/5±
 pidigits±
 Ruby 2.0 used what fraction? used how many times more? 
Time-used  |-  |---  25% median  75%  ---|  -|
(Elapsed secs)1/21/21/2±±

± read the measurements and then read the program source code.

 3 : Are the Ruby 2.0 programs faster? Measurements.

These are not the only tasks that could be solved. These are just 10 tiny examples. These are not the only compilers and interpreters. These are not the only programs that could be written.

For each named benchmark, measurements of the fastest Ruby 2.0 program are shown for comparison against measurements of the fastest Python 3 program.

Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
 spectral-norm 
Ruby 2.0320.35320.457,732326  0% 0% 0% 100%
Python 3787.37787.627,096328  0% 0% 0% 100%
 binary-trees 
Ruby 2.0199.54199.69436,916439  0% 0% 0% 100%
Python 3480.36480.871,209,444626  0% 0% 0% 100%
 fasta 
Ruby 2.0106.88106.93223,864772  0% 0% 0% 100%
Python 3217.54221.686,216792  0% 0% 1% 100%
 n-body 
Ruby 2.0666.58666.726,1721137  0% 0% 0% 100%
Python 3916.32916.596,2961181  0% 0% 0% 100%
 mandelbrot 
Ruby 2.01,832.091,832.556,136307  0% 0% 0% 100%
Python 31,729.801,730.60100,660777  0% 0% 0% 100%
 regex-dna 
Ruby 2.030.0730.09393,896417  0% 0% 0% 100%
Python 321.7521.77200,012424  0% 0% 0% 100%
 k-nucleotide 
Ruby 2.0544.77545.08227,564540  0% 0% 0% 100%
Python 3388.14388.47487,132647  0% 0% 0% 100%
 fannkuch-redux 
Ruby 2.03,341.033,341.916,148384  0% 0% 0% 100%
Python 32,348.562,349.266,152385  0% 0% 0% 100%
 reverse-complement 
Ruby 2.09.039.04128,252255  0% 0% 0% 100%
Python 35.385.40675,272325  0% 0% 0% 100%
 pidigits 
Ruby 2.09.489.4914,988242  0% 0% 1% 100%
Python 32.402.406,928255  2% 0% 0% 100%
 fasta-redux
   No programs

 4 : Are there other Ruby 2.0 programs for these benchmarks?

Remember - those are just the fastest Ruby 2.0 and Python 3 programs measured on this OS/machine. Check if there are other implementations of these benchmark programs for Ruby 2.0.

Maybe one of those other Ruby 2.0 programs is fastest on a different OS/machine.

 5 : Are there other faster programs for these benchmarks?

Remember - those are just the fastest Ruby 2.0 and Python 3 programs measured on this OS/machine. Check if there are faster implementations of these benchmark programs for other programming languages.

Maybe one of those other programs is fastest on a different OS/machine.

 Ruby 2.0 : the new Ruby 

online book Programming Ruby: The Pragmatic Programmers Guide

ruby 2.0.0p0 (2013-02-24 revision 39474) [x86_64-linux]

Home Page: Ruby is…

Download: Ruby 2.0.0-p0 is released

Revised BSD license

  Home   Conclusions   License   Play