/mobile Handheld Friendly website

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

Each chart bar shows how many times slower, one ↓ k-nucleotide 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.0Ada 2005 GNAT #2 23.1123.15253,4804865  0% 0% 0% 100%
1.0C++ g++ #3 23.6923.71137,4481252  1% 0% 0% 100%
1.3Scala #2 29.9529.97216,7482080  0% 0% 0% 100%
1.4ATS #2 32.1532.17124,1323238  0% 0% 0% 100%
1.6C gcc #7 37.5237.56153,4242280  0% 0% 0% 100%
2.1Pascal Free Pascal #2 48.6448.66128,3962383  0% 0% 0% 100%
2.2ATS #3 50.3250.35132,0963810  0% 0% 0% 100%
2.2Java 7  #3 50.6950.73494,0401630  1% 0% 0% 100%
2.2Go #5 51.6951.73260,2121268  1% 2% 0% 100%
2.2C gcc #6 51.9852.03153,4242439  0% 0% 0% 100%
2.2Java 7  #2 51.9952.04494,7281602  1% 0% 0% 100%
2.6Fortran Intel #2 60.7860.82166,8682079  1% 0% 0% 100%
3.0Lisp SBCL #5 69.1169.19105,2402301  0% 0% 0% 100%
3.0Lisp SBCL #4 69.1169.19105,2362272  0% 0% 0% 100%
3.1Haskell GHC #3 71.5571.61308,8602749  0% 0% 0% 100%
3.1Haskell GHC #2 72.1672.22349,4961965  0% 0% 0% 100%
4.0Scala #6 93.0593.16486,1281380  0% 0% 0% 100%
4.5C# Mono #3 103.34103.42577,5161404  0% 0% 0% 100%
4.5C# Mono #4 103.85103.92498,1201696  1% 0% 0% 100%
4.5Clojure #6 103.92104.011,012,0001737  0% 0% 0% 100%
4.8C# Mono 109.98110.04469,3281420  0% 0% 0% 100%
5.0Fortran Intel 114.85114.91179,3762238  0% 0% 0% 100%
5.7Clojure #7 132.66133.081,006,5403030  0% 0% 1% 100%
6.5C# Mono #5 150.33150.45472,0282445  0% 0% 0% 100%
7.6Lisp SBCL #3 175.19175.28355,0921284  0% 0% 0% 100%
7.7Go 175.18178.47381,084980  1% 0% 0% 100%
7.9Lisp SBCL #2 183.11183.21355,0921277  0% 0% 0% 100%
7.9Clojure #4 183.62183.771,003,8761944  0% 0% 0% 100%
8.5C# Mono #2 195.69195.85595,3201012  1% 0% 0% 100%
9.1Perl #2 206.30209.52707,940359  0% 0% 0% 100%
9.5Lua #2 220.11220.81707,928613  0% 0% 0% 100%
9.8Racket 225.97226.511,419,356542  0% 0% 0% 100%
12F# Mono 267.03267.45566,116701  0% 0% 0% 100%
12Erlang HiPE #3 267.32267.521,045,072932  0% 0% 0% 100%
13PHP #4 5 min5 min246,8041060  0% 0% 0% 100%
14Smalltalk VisualWorks #5 5 min5 min343,3201153  0% 0% 0% 100%
14Haskell GHC 5 min5 min257,9841693  0% 0% 0% 100%
15JavaScript V8 #2 5 min5 min429,952451  0% 0% 0% 100%
21Python 3 #8 7 min7 min426,212647  1% 0% 0% 100%
22Ruby JRuby 8 min8 min1,274,752637  0% 0% 0% 100%
22Ruby JRuby #3 8 min8 min1,275,048540  1% 0% 0% 100%
26Python 3 9 min9 min360,936487  0% 0% 0% 100%
33Ruby 2.0 #2 12 min12 min158,084420  0% 0% 0% 100%
35Ruby 2.0 #3 13 min13 min218,616540  0% 0% 0% 100%
38Ruby 2.0 14 min14 min128,016637  0% 0% 0% 100%
C CINT Timed Out1h 00 min1224
C++ g++ Make Error2106
Erlang HiPE Failed930
Erlang HiPE #2 Failed997
JavaScript V8 #3 Timed Out1h 00 min390
JavaScript V8 Timed Out1h 00 min423
Lisp SBCL Bad Output847
OCaml #3 Failed1789
OCaml Failed870
OCaml #2 Failed1205
Perl Failed648
Racket #2 Bad Output842
Racket #4 Bad Output881
Ruby JRuby #2 Failed421
Scala #4 Failed1287
Scala Failed1625
"wrong" (different) algorithm / less comparable programs
0.4C++ g++ #5 9.409.4141,2523416
0.5Java 7  10.5710.59152,2525211
0.5C++ g++ #6 11.3511.37132,6083415
0.5Ada 2005 GNAT 11.8411.85399,0646503
0.5C gcc #4 12.5712.59162,2162409
1.7C# Mono #6 38.1438.90108,0041433
2.2C gcc #5 51.3551.39267,3442519
5.4Python 3 #2 123.50124.75475,820624
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