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 2.800.89293,3921009  80% 94% 74% 78%
1.1PyPy 2 2.860.9580,3201009  73% 94% 68% 72%
1.1PyPy 2 2.840.98296,1041009  74% 82% 71% 71%
1.3PyPy 3 #2 3.131.2077,4201008  63% 60% 56% 91%
1.4PyPy 3 3.251.2578,7601271  94% 58% 58% 58%
1.4PyPy 3 3.261.2579,4401271  94% 58% 59% 59%
1.4PyPy 3 #6 1.241.2665,064552  5% 2% 1% 99%
1.4PyPy 3 3.291.2679,0801271  61% 58% 56% 92%
1.4PyPy 3 #2 3.211.2777,3001008  59% 57% 87% 58%
1.4PyPy 3 #2 3.201.2877,5481008  60% 87% 56% 57%
1.4PyPy 3 #3 3.791.2979,048894  71% 68% 68% 95%
1.5PyPy 3 #6 1.271.2964,904552  9% 2% 98% 2%
1.5PyPy 3 #6 1.241.3065,192552  100% 1% 0% 0%
1.5PyPy 3 #3 3.811.3579,412894  69% 62% 65% 94%
1.6PyPy 3 #4 4.101.3979,5481069  74% 92% 69% 68%
1.6PyPy 3 #4 4.131.3979,0681069  72% 94% 71% 69%
1.6PyPy 3 #3 3.831.3977,532894  64% 92% 63% 64%
1.7PyPy 3 #4 4.231.4778,9521069  95% 66% 66% 68%
3.1Pyston 10.352.73158,5601009  95% 93% 99% 94%
3.2Pyston 10.382.83157,8721009  92% 89% 95% 91%
3.2Cython 10.152.8653,2721027  97% 98% 94% 98%
3.3Pyston 10.422.89157,5841009  87% 90% 89% 96%
3.3Cython 10.102.9252,9441027  92% 92% 86% 94%
3.3Nuitka #3 10.602.9756,428894  95% 95% 90% 97%
3.3Nuitka #4 10.722.9757,0041069  95% 95% 96% 89%
3.4Cython 10.142.9852,3321027  96% 94% 94% 88%
3.4Nuitka #3 10.593.0056,904894  99% 97% 94% 97%
3.4Nuitka #4 10.813.0355,9001069  96% 96% 94% 88%
3.4Nuitka #3 10.643.0456,044894  94% 92% 88% 94%
3.5Graal #6 3.613.09486,156552  24% 7% 23% 94%
3.5Graal #6 3.673.13483,772552  22% 23% 29% 72%
3.6Nuitka #4 11.473.1756,9601069  96% 94% 93% 93%
3.7Python development version #3 12.393.2652,732894  96% 94% 98% 95%
3.7Graal #6 3.863.26493,600552  19% 43% 86% 10%
3.7Python development version #3 12.483.2852,352894  92% 96% 96% 98%
3.8Python development version #4 12.763.3652,5801069  95% 96% 95% 99%
3.8Python development version #3 12.513.4052,376894  96% 89% 95% 92%
3.8Python development version #4 12.933.4052,5921069  100% 92% 97% 96%
3.9Python 3 #3 11.833.4652,828894  97% 96% 90% 97%
3.9Python development version #4 12.803.4652,6161069  96% 96% 90% 95%
4.0Python 3 #4 12.583.5552,9441069  95% 98% 90% 94%
4.0Python 3 #4 12.493.5852,4961069  96% 91% 92% 93%
4.1Python 3 #4 12.493.6253,0521069  93% 92% 96% 90%
4.1Python 3 #3 12.113.6652,808894  96% 93% 93% 95%
4.1Python 3 #3 11.923.6853,056894  94% 95% 93% 96%
4.5Nuitka #2 14.574.0456,8481008  97% 95% 97% 94%
4.9Python 2 16.554.3741,9321009  97% 98% 96% 96%
4.9Python 2 16.304.3743,2921009  96% 95% 94% 95%
5.1Nuitka #2 14.844.5256,4721008  98% 95% 95% 94%
5.1Nuitka 16.434.5757,0161271  99% 97% 99% 98%
5.2Python 2 17.084.6543,6201009  97% 96% 98% 97%
5.6Python development version #2 18.734.9752,1801008  97% 95% 94% 95%
5.6Python development version #2 19.214.9952,3241008  98% 97% 98% 96%
5.6Nuitka #6 4.995.009,524552  3% 7% 2% 100%
5.7Python development version #2 19.245.0952,0521008  94% 95% 95% 98%
5.8Nuitka #6 5.105.119,360552  8% 8% 100% 3%
5.8Python 3 #2 18.195.1752,8721008  97% 99% 95% 96%
5.8Nuitka #2 14.115.1756,2841008  98% 99% 97% 99%
5.9Nuitka #6 5.225.239,468552  10% 14% 3% 100%
5.9Python 3 #2 18.255.2752,8681008  99% 98% 97% 97%
6.1Python 3 #2 18.155.3853,0001008  93% 98% 98% 97%
6.3Python development version 21.685.5652,1601271  98% 99% 99% 98%
6.4Python development version 21.785.6752,8041271  95% 98% 98% 99%
6.4Python development version 21.885.7152,2041271  99% 95% 97% 98%
6.6Python 3 21.445.8852,5641271  97% 98% 94% 97%
6.7Python 3 21.465.9353,2081271  94% 98% 97% 93%
6.8Python 3 21.766.0153,3241271  95% 95% 98% 95%
7.2Python development version #6 6.366.378,456552  2% 100% 0% 0%
7.2Python development version #6 6.406.418,516552  3% 3% 1% 100%
7.2Python development version #6 6.426.438,412552  2% 1% 100% 1%
7.3Python 3 #6 6.496.508,548552  12% 100% 10% 8%
7.3Nuitka 16.516.5058,0961271  99% 99% 100% 99%
7.4Python 3 #6 6.586.598,440552  20% 100% 10% 11%
7.6Nuitka 16.596.7257,4321271  98% 99% 99% 98%
7.6Python 3 #6 6.506.798,452552  90% 19% 9% 7%
9.5MicroPython #6 8.438.464,188552  87% 15% 7% 6%
9.7MicroPython #6 8.548.584,048552  6% 58% 6% 49%
9.7MicroPython #6 8.618.654,192552  88% 19% 7% 7%
missing benchmark programs
Jython No program
IronPython No program
Shedskin No program
Numba 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