1 : At a glance - Are the Python 3 programs faster?

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

(Memory use is only compared for tasks that require memory to be allocated.)


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 : Approximately - Are the Python 3 programs faster?

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

(Memory use is only compared for tasks that require memory to be allocated.)

 Python 3 used what fraction? used how many times more? 
Benchmark Time Memory Code
 pidigits1/23 1/3
 regex-dna1/21/21/2
 reverse-complement †±±
 k-nucleotide1/3±
 binary-trees †±
 fasta10× ±
 fannkuch-redux23× ±
 spectral-norm31× 1/2
 mandelbrot35× ±
 n-body43× ±
 Python 3 used what fraction? used how many times more? 
Time-used  |-  |---  25% median  75%  ---|  -|
(Elapsed secs)1/231/2331×43×43×

† possible mismatch - one-core program compared to multi-core program.

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

 3 : Measurements - Are the Python 3 programs faster?

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 Python 3 program are shown for comparison against measurements of the fastest C# Mono program.

Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
 pidigits 
Python 32.742.745,400335  0% 1% 100% 0%
C# Mono62.9162.7664,548856  1% 38% 62% 1%
 regex-dna 
Python 323.4910.58253,208478  47% 39% 94% 43%
C# Mono88.1726.23435,892898  86% 86% 83% 82%
 reverse-complement 
Python 35.453.72259,780800  30% 1% 72% 47% †
C# Mono1.681.68195,5961099  2% 1% 1% 98% †
 k-nucleotide 
Python 3291.9475.78148,1921937  97% 97% 100% 97%
C# Mono71.7624.59505,8721822  66% 68% 94% 65%
 binary-trees 
Python 3470.42125.06470,428596  93% 97% 94% 94% †
C# Mono21.4320.39116,392654  6% 1% 100% 0% †
 fasta 
Python 3127.5445.962,479,9041933  76% 65% 78% 80%
C# Mono10.534.55130,1161505  66% 61% 62% 44%
 fannkuch-redux 
Python 32,582.98654.6128,068944  100% 99% 98% 98%
C# Mono112.6428.7739,3641096  99% 99% 98% 96%
 spectral-norm 
Python 31,004.46252.9230,320437  99% 100% 99% 99%
C# Mono31.688.1738,4121063  97% 97% 98% 97%
 mandelbrot 
Python 31,106.61277.2728,372686  100% 100% 100% 100%
C# Mono30.667.8874,868986  97% 97% 99% 97%
 n-body 
Python 3993.47993.704,2401181  0% 0% 100% 1%
C# Mono23.1623.1738,7521410  1% 0% 0% 100%
 fasta-redux 
No program
C# Mono0.230.247721438  17% 0% 8% 83%

† possible mismatch - one-core program compared to multi-core program.

 4 : Are there other Python 3 programs for these benchmarks?

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

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

 5 : Are there other faster programs for these benchmarks?

Remember - those are just the fastest Python 3 and C# Mono 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.

 Python 3 : the new Python 

Python 3.4.3 (default, Apr 5 2015, 10:03:09) [GCC 4.8.2] on linux

"3.x is the newest branch of Python and the intended future of the language."

"Van Rossum: Python is not too slow"

Home Page: Python 3.4.3 was released Wednesday, February 25th, 2015.

Revised BSD license

  Home   Conclusions   License   Play