vs

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

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

Each table row shows, for one named benchmark, how much the fastest Python 2 program used compared to the fastest PyPy program.

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

 Python 2 used what fraction? used how many times more? 
Benchmark Time Memory Code
 pidigits1/55 ±
 reverse-complement1/8?±
 regex-dna1/4?±
 templates1/3 ±
 spectral-norm1/2?1/2
 mandelbrot1/2 ±
 k-nucleotide1/2?±
 chameneos-redux± ±
 binary-trees±1/6±
 iobench ±
 pystone?±
 fibonacci ±
 fasta ±
 meteor-contest ±
 jsonbench ±
 thread-ring?±
 fib50 ±
 richards ±
 fannkuch-redux ±
 n-body ±
 Python 2 used what fraction? used how many times more? 
Time-used  |-  |---  25% median  75%  ---|  -|
(Elapsed secs)1/551/551/2

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

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

Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
 pidigits 
Python 20.010.01?380  0% 0% 0% 100%
PyPy0.660.6686,928380  3% 3% 100% 0%
 reverse-complement 
Python 20.010.01?455  0% 100% 0% 0%
PyPy0.080.08?455  100% 0% 0% 0%
 regex-dna 
Python 20.030.03?501  100% 0% 0% 0%
PyPy0.140.14?501  100% 0% 0% 0%
 templates 
Python 21.051.0516,332307  0% 0% 0% 100%
PyPy2.662.6792,116307  0% 100% 0% 0%
 spectral-norm 
Python 20.070.07?394  0% 0% 86% 0%
PyPy0.150.15?594  100% 0% 0% 0%
 mandelbrot 
Python 274.8719.17173,5243832  97% 98% 99% 97%
PyPy130.0733.95126,2883832  96% 98% 98% 98%
 k-nucleotide 
Python 20.080.08?593  0% 11% 100% 0%
PyPy0.110.12?593  100% 0% 0% 0%
 chameneos-redux 
Python 2113.1162.6911,0761192  34% 30% 32% 33%
PyPy103.6456.0078,3121192  34% 34% 37% 39%
 binary-trees 
Python 23.771.1454,152743  82% 81% 82% 90%
PyPy2.191.01322,228743  78% 70% 61% 58%
 iobench 
Python 225.2125.216,804370  0% 79% 0% 21%
PyPy12.6912.6983,968370  0% 100% 0% 0%
 pystone 
Python 20.230.238442301  0% 100% 4% 4%
PyPy0.110.11?2301  0% 0% 0% 100%
 fibonacci 
Python 20.660.677,128181  0% 0% 0% 100%
PyPy0.280.281,636181  100% 0% 0% 0%
 fasta 
Python 26.466.4613,432900  0% 75% 0% 25%
PyPy2.382.3977,848900  0% 0% 100% 0%
 meteor-contest 
Python 22.652.656,8681485  0% 84% 0% 16%
PyPy0.860.8682,2321579  1% 0% 100% 0%
 jsonbench 
Python 24.364.3716,424322  0% 0% 100% 0%
PyPy1.261.2679,572322  1% 2% 2% 100%
 thread-ring 
Python 20.550.557,072407  2% 100% 0% 2%
PyPy0.150.15?407  0% 0% 100% 0%
 fib50 
Python 22.842.8438,432136  0% 0% 100% 0%
PyPy0.650.6577,608136  0% 100% 0% 2%
 richards 
Python 21.171.177,1322423  1% 1% 100% 0%
PyPy0.250.251,6802423  100% 4% 12% 0%
 fannkuch-redux 
Python 215.914.1342,7081009  95% 97% 96% 98%
PyPy2.820.89285,6001009  78% 75% 97% 72%
 n-body 
Python 250.8250.826,7561337  100% 0% 0% 0%
PyPy6.906.9072,4921337  100% 0% 0% 0%
 fasta-redux 
No program
PyPy0.280.281,6921115  0% 57% 29% 19%
 binary-trees-redux
   No programs

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

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

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

 5 : Are there other faster programs for these benchmarks?

Remember - those are just the fastest Python 2 and PyPy 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 2 : the old Python 

 

Revised BSD license

  Home   Conclusions   License   Play