/mobile Handheld Friendly website

 k-nucleotide benchmark ≈240MB N=25,000,000

Each chart bar shows how many times more Memory, one ↓ k-nucleotide program used, compared to the program that used least Memory.

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.

    sortsort sort
  ×   Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
1.0Rust 28.4128.44129,3322049  1% 1% 0% 100%
1.0Pascal Free Pascal #2 86.0586.09130,5682383  91% 0% 0% 9%
1.0Ruby 8 min143.44131,008637  96% 80% 95% 72%
1.1Lisp SBCL #5 37.0937.13138,4842301  0% 0% 1% 100%
1.1Lisp SBCL #4 37.0837.12138,4882272  0% 1% 1% 100%
1.2C++ g++ #3 24.417.33155,9241252  79% 80% 81% 95%
1.3Ruby #2 7 min7 min167,228420  1% 100% 0% 0%
1.3Ruby #3 7 min7 min170,312540  26% 25% 23% 27%
1.3Scala #2 25.109.23171,4642080  55% 76% 69% 73%
1.4C gcc #7 43.9916.22180,3722280  38% 97% 97% 41%
1.4C gcc #6 59.6819.71180,3722439  97% 98% 54% 55%
1.4Java  #4 61.2260.65186,3801873  70% 1% 1% 31%
1.4Fortran Intel 88.6088.68187,1202238  0% 0% 100% 0%
1.5Java  #5 78.9336.26193,2162211  17% 88% 20% 95%
1.5Fortran Intel #2 65.5225.74196,2122079  48% 38% 90% 83%
1.7Hack #4 137.0542.82221,9601061  66% 94% 74% 89%
1.9PHP #4 5 min94.40247,7241060  97% 76% 76% 82%
1.9PHP 43.0837.93247,8321036  4% 91% 4% 16%
2.0OCaml #3 55.5020.29253,6241789  39% 57% 79% 100%
2.0Ada 2005 GNAT #2 31.9012.52256,1284865  85% 65% 52% 54%
2.0Go #2 144.3849.56256,9161531  62% 57% 88% 87%
2.0Go #5 76.0628.90261,9961268  37% 48% 83% 97%
2.3C# Mono #2 143.28143.31302,1121012  95% 1% 1% 5%
2.4Haskell GHC #3 122.1146.26313,5082749  54% 89% 43% 80%
2.5OCaml #2 82.4737.09325,7401205  26% 80% 36% 82%
2.6Lisp SBCL #2 145.75145.86331,2201277  0% 0% 1% 100%
2.6Lisp SBCL #3 141.54141.61331,2201284  0% 1% 1% 100%
2.6C# Mono #3 96.5831.05334,6721404  97% 68% 70% 78%
2.8Haskell GHC 65.9917.73363,7801693  92% 93% 93% 97%
2.8Haskell GHC #2 74.8220.03365,1121965  96% 92% 95% 92%
2.9Go 189.2863.63380,512980  86% 60% 92% 61%
3.0Racket #4 106.84106.83387,480881  0% 0% 1% 100%
3.1Python 3 7 min7 min402,016487  0% 1% 100% 0%
3.4OCaml 69.4569.51443,232870  96% 0% 0% 4%
3.5C# Mono #5 145.4951.21449,7442445  69% 78% 70% 69%
3.8Scala #6 191.4252.66492,5801380  91% 91% 91% 91%
3.9Python 3 #8 6 min124.40498,756647  59% 58% 87% 98%
3.9Ruby #4 112.75112.79501,972449  1% 100% 0% 0%
3.9Java  #2 44.8512.81504,3121602  93% 86% 87% 84%
3.9Java  #3 46.4913.13504,9521630  86% 84% 86% 99%
3.9Clojure #5 35.9513.12506,0802723  58% 79% 56% 82%
4.2C# Mono 95.7095.74538,8121420  3% 1% 1% 97%
4.4C# Mono #4 89.0428.88563,9961696  71% 96% 70% 72%
4.9F# Mono #3 73.2331.12628,3841111  70% 69% 34% 65%
5.1F# Mono 295.43103.51662,576701  77% 73% 74% 59%
5.1F# Mono #4 74.5627.44663,1761505  99% 49% 66% 59%
6.0Perl #2 221.13224.63778,212359  97% 1% 0% 0%
7.0Ruby JRuby #3 9 min183.31907,264540  76% 91% 66% 85%
7.3Ruby JRuby 8 min167.76944,148637  91% 79% 82% 65%
7.7Clojure #4 221.8068.67993,0481944  86% 73% 78% 86%
7.7Erlang #3 7 min157.60996,280932  80% 73% 64% 57%
7.9Clojure #7 128.7739.071,024,4803030  84% 80% 86% 81%
8.2Perl #4 221.6971.041,066,204472  61% 96% 90% 67%
8.3Clojure #6 146.8754.371,075,3001737  46% 77% 83% 67%
8.8Erlang HiPE #3 6 min143.111,133,724932  68% 78% 64% 60%
8.8Perl #3 278.3584.541,143,524507  72% 75% 94% 90%
10Racket 190.80190.941,308,984542  29% 1% 66% 5%
14Ruby JRuby #4 92.2383.491,825,996449  5% 55% 47% 5%
15Perl 240.6070.321,886,164648  84% 90% 82% 87%
28Erlang 7 min195.373,684,516930  82% 49% 58% 73%
29Erlang HiPE 6 min181.003,734,268930  84% 50% 53% 68%
C++ g++ Make Error2106
Erlang #2 Failed997
Erlang HiPE #2 Failed997
Hack Bad Output1038
Lisp SBCL Timed Out10 min847
Racket #2 Bad Output842
Ruby JRuby #2 Failed421
Scala Failed1625
Scala #4 Failed1287
"wrong" (different) algorithm / less comparable programs
0.4C++ g++ #5 7.432.4549,4003416
1.0C gcc #8 8.868.87128,1082040
1.1C++ g++ #6 10.803.08139,0203415
1.3C gcc #4 8.852.65174,4682409
1.6Java  12.643.64200,9245211
2.2C gcc #5 57.1618.05282,0202519
2.9Python 3 #2 93.3351.67376,064624
3.1Ada 2005 GNAT 14.127.04395,1126503
7.8C# Mono #6 43.8115.191,013,2081433
missing benchmark programs
Dart No program

 k-nucleotide benchmark : Hashtable update and k-nucleotide strings

diff program output for this 250KB input file (generated with the fasta program N = 25000) 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.

We use FASTA files generated by the fasta benchmark as input for this benchmark. Note: the file may include both lowercase and uppercase codes.

Each program should

In practice, less brute-force would be used to calculate k-nucleotide frequencies, for example Virus Classification using k-nucleotide Frequencies and A Fast Algorithm for the Exhaustive Analysis of 12-Nucleotide-Long DNA Sequences. Applications to Human Genomics (105KB pdf).

Revised BSD license

  Home   Conclusions   License   Play