vs

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

Each chart bar shows, for one unidentified benchmark, how much the fastest Python 3 program used compared to the fastest PyPy 3 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 : Are the Python 3 programs faster? Approximately.

Each table row shows, for one named benchmark, how much the fastest Python 3 program used compared to the fastest PyPy 3 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/101 ±
 templates1/4 ±
 regex-dna1/4 ±
 reverse-complement1/3?±
 iobench1/2 ±
 k-nucleotide †1/2?±
 spectral-norm± 1/2
 binary-trees±1/2±
 fasta-redux± ±
 chameneos-redux ±
 fasta † ±
 fibonacci ±
 fannkuch-redux ±
 jsonbench ±
 meteor-contest ±
 richards ±
 fib50 ±
 n-body10× ±
 thread-ring †147×?±
 Python 3 used what fraction? used how many times more? 
Time-used  |-  |---  25% median  75%  ---|  -|
(Elapsed secs)1/1011/1011/2147×

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

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

 3 : Are the Python 3 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 Python 3 program are shown for comparison against measurements of the fastest PyPy 3 program.

Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
 pidigits 
Python 30.030.03?379  100% 0% 0% 0%
PyPy 32.953.1278,516322  99% 1% 0% 1%
 templates 
Python 31.031.0319,980322  8% 100% 1% 1%
PyPy 34.294.42110,616322  54% 1% 48% 1%
 regex-dna 
Python 30.050.06?524  17% 100% 0% 0%
PyPy 30.230.231,000524  4% 0% 100% 0%
 reverse-complement 
Python 30.020.03?449  0% 100% 0% 0%
PyPy 30.090.09?449  10% 100% 0% 0%
 iobench 
Python 35.535.539,000367  5% 94% 0% 6%
PyPy 312.4812.5176,916367  5% 0% 80% 21%
 k-nucleotide 
Python 30.090.07?801  14% 14% 14% 88% †
PyPy 30.140.14?594  0% 0% 7% 100% †
 spectral-norm 
Python 30.140.15?394  13% 100% 0% 0%
PyPy 30.200.211,092594  0% 5% 5% 100%
 binary-trees 
Python 33.200.9658,724741  86% 91% 86% 83%
PyPy 32.051.08138,904741  40% 76% 38% 44%
 fasta-redux 
Python 30.270.271,7801115  11% 0% 0% 100%
PyPy 30.240.249681115  8% 0% 0% 100%
 chameneos-redux 
Python 3353.29175.808,9561191  48% 40% 47% 47%
PyPy 3195.47101.3667,9641191  50% 36% 43% 41%
 fasta 
Python 37.824.22104,0842016  50% 75% 56% 10% †
PyPy 31.972.0868,9281698  99% 1% 1% 0% †
 fibonacci 
Python 30.680.689,316182  6% 0% 100% 0%
PyPy 30.270.281,056182  100% 0% 0% 4%
 fannkuch-redux 
Python 313.033.4448,036894  97% 99% 91% 99%
PyPy 33.331.3179,3241271  59% 92% 54% 55%
 jsonbench 
Python 33.293.2912,396322  5% 0% 1% 100%
PyPy 31.211.2375,232322  6% 1% 98% 2%
 meteor-contest 
Python 33.203.218,9201443  5% 100% 1% 1%
PyPy 30.910.9175,9721443  5% 0% 1% 100%
 richards 
Python 31.091.109,0082434  5% 0% 0% 100%
PyPy 30.280.289562434  7% 4% 97% 0%
 fib50 
Python 33.393.468,396136  43% 1% 59% 1%
PyPy 30.770.7772,360136  5% 99% 1% 0%
 n-body 
Python 346.5346.908,8121315  21% 0% 83% 1%
PyPy 34.574.5968,3401315  5% 1% 0% 100%
 thread-ring 
Python 334.1324.1813,204448  23% 37% 20% 48% †
PyPy 30.160.17?407  0% 100% 0% 0% †
 pystone 
No program
PyPy 30.120.12?2303  8% 92% 0% 0%
 mandelbrot
   No programs
 binary-trees-redux
   No programs

† 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 PyPy 3 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 PyPy 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.

 Python 3 : the new Python 

Python 3.3.1 (default, Apr 11 2013, 12:45:45)
[GCC 4.7.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.3.1 was released on April 7th, 2013.

Revised BSD license

  Home   Conclusions   License   Play