fannkuch-redux benchmark N=10

Each chart bar shows how many times slower, one ↓ fannkuch-redux program was, compared to the fastest program.

These are not the only programs that could be written. These are not the only compilers and interpreters. These are not the only programming languages.

Column × shows how many times more each program used compared to the benchmark program that used least.

    sort sortsort
  ×   Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
1.0PyPy 2 4.181.2479,1201009  80% 79% 98% 80%
1.1PyPy 2 4.201.3477,5201009  75% 91% 75% 75%
1.1PyPy 2 4.201.3479,3841009  75% 91% 72% 77%
1.2PyPy 3 #6 1.451.4563,960552  0% 8% 94% 1%
1.2PyPy 3 #6 1.451.4663,572552  0% 1% 6% 100%
1.2PyPy 3 #6 1.461.4663,808552  0% 1% 1% 100%
1.3PyPy 3 #2 4.551.6276,2681008  64% 64% 94% 62%
1.3PyPy 3 4.571.6277,5681271  62% 63% 64% 94%
1.3PyPy 3 #2 4.501.6276,3801008  63% 94% 60% 63%
1.3PyPy 3 4.611.6375,5441271  64% 63% 94% 63%
1.3PyPy 3 4.611.6475,0161271  88% 63% 65% 67%
1.3PyPy 3 #2 4.551.6476,0001008  94% 62% 62% 61%
1.7PyPy 3 #3 6.802.1576,084894  74% 72% 97% 75%
1.8PyPy 3 #3 6.712.2375,844894  70% 69% 73% 92%
1.8PyPy 3 #4 6.882.2477,3601069  71% 73% 71% 94%
1.8PyPy 3 #4 6.872.2475,0041069  71% 77% 91% 70%
1.8PyPy 3 #3 6.932.2475,636894  74% 73% 96% 75%
1.8PyPy 3 #4 6.902.2574,9361069  94% 71% 74% 74%
3.3Nuitka #3 15.764.0961,752894  97% 99% 95% 96%
3.4Nuitka #3 15.984.1961,080894  97% 98% 96% 97%
3.4Nuitka #3 15.784.1963,080894  95% 96% 96% 94%
3.4Nuitka #4 16.254.2861,0561069  98% 95% 97% 95%
3.4Nuitka #4 16.314.2961,7521069  96% 100% 94% 96%
3.5Nuitka #4 16.364.2963,2121069  95% 97% 96% 94%
4.2Python 3 #3 20.195.2855,404894  98% 97% 96% 97%
4.2Python 3 #3 20.075.2855,292894  96% 95% 97% 97%
4.3Python 3 #3 20.325.2855,780894  97% 98% 96% 98%
4.3Python 3 #4 20.955.3855,7041069  97% 97% 98% 99%
4.4Python 3 #4 20.935.4856,1041069  96% 96% 97% 97%
4.4Python 3 #4 20.845.4957,2921069  97% 96% 97% 95%
4.7Nuitka #2 22.205.7963,3161008  97% 98% 95% 98%
4.7Nuitka #2 22.385.8960,4561008  95% 95% 97% 96%
4.8Nuitka #2 23.295.9962,4321008  98% 96% 98% 97%
4.9Nuitka #6 6.106.1010,404552  1% 0% 100% 1%
4.9Nuitka #6 6.146.1410,328552  100% 2% 1% 0%
4.9Nuitka #6 6.156.1510,316552  100% 1% 1% 0%
5.1Python development version #4 24.616.3853,8521069  97% 98% 99% 98%
5.1Python development version #4 24.316.3852,4361069  97% 99% 95% 97%
5.2Python development version #4 24.646.4852,4281069  98% 97% 98% 97%
5.3Python development version #3 23.336.5854,500894  96% 99% 97% 97%
5.3Python development version #3 23.286.5953,188894  95% 97% 97% 98%
5.4Nuitka 26.086.7061,9001271  99% 97% 97% 97%
5.5Cython 25.526.7952,6561271  97% 94% 95% 98%
5.5Cython 25.896.8954,5401271  99% 96% 96% 96%
5.5Nuitka 26.636.8960,6841271  99% 97% 96% 97%
5.5Nuitka 26.806.8960,1441271  99% 99% 97% 99%
5.6Cython 25.676.9953,7961271  96% 92% 98% 91%
5.8Python development version #3 22.917.1952,908894  92% 98% 95% 98%
5.9Python 2 28.477.3546,1521009  97% 98% 99% 98%
5.9Python 2 28.307.3544,4681009  98% 97% 97% 97%
5.9Python 2 28.517.3644,1121009  98% 98% 97% 98%
6.2Python 3 #2 29.887.6856,4321008  99% 98% 98% 98%
6.2Python 3 #2 29.787.6955,2761008  99% 97% 98% 97%
6.3Python 3 #2 29.727.7858,0121008  97% 98% 96% 96%
6.7Python 3 #6 8.338.348,788552  2% 0% 1% 100%
6.7Python 3 #6 8.348.348,692552  0% 100% 0% 0%
6.7Python 3 #6 8.358.368,716552  1% 100% 1% 0%
7.2Python 3 34.538.9855,0241271  98% 99% 96% 96%
7.2Python 3 34.638.9857,3881271  98% 98% 97% 97%
7.2Python 3 34.538.9955,6121271  98% 97% 97% 98%
7.3Python development version #2 34.939.0852,4281008  98% 98% 96% 98%
7.3Python development version #2 34.969.0954,6921008  99% 97% 99% 97%
7.4Python development version #2 34.989.1952,6321008  98% 95% 98% 96%
7.6Python development version #6 9.479.487,436552  4% 100% 2% 1%
7.7Python development version #6 9.539.547,476552  12% 91% 3% 1%
7.7Python development version #6 9.559.557,372552  32% 3% 69% 1%
8.4MicroPython #6 10.4110.414,044552  25% 1% 78% 1%
8.4MicroPython #6 10.4710.474,128552  4% 1% 100% 2%
8.4MicroPython #6 10.4710.474,020552  2% 3% 0% 100%
8.7Python development version 41.0910.7952,6921271  96% 98% 98% 98%
8.7Python development version 40.8910.7954,5441271  98% 100% 95% 97%
8.9Python development version 40.7911.0952,6841271  95% 96% 97% 98%
missing benchmark programs
Jython No program
IronPython No program
Shedskin No program
Numba No program
Pyston No program
Grumpy No program

 fannkuch-redux benchmark : Indexed-access to tiny integer-sequence

diff program output N = 7 with this output file to check your program is correct before contributing.

We are trying to show the performance of various programming language implementations - so we ask that contributed programs not only give the correct result, but also use the same algorithm to calculate that result.

For N = 7 programs should generate these permutations (40KB) - which, incidentally, seem to be in the same order as permutations generated by the Tompkins-Paige algorithm, see pages 150-151 Permutation Generation Methods Robert Sedgewick.

The fannkuch benchmark is defined by programs in Performing Lisp Analysis of the FANNKUCH Benchmark, Kenneth R. Anderson and Duane Rettig.

Each program should

The conjecture is that this maximum count is approximated by n*log(n) when n goes to infinity.

FANNKUCH is an abbreviation for the German word Pfannkuchen, or pancakes, in analogy to flipping pancakes.


Thanks to Oleg Mazurov for insisting on a checksum and providing this helpful description of the approach he took -

Revised BSD license

  Home   Conclusions   License   Play