fasta benchmark ≈240MB N=25,000,000

Each chart bar shows how many times slower, one ↓ fasta 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.0Fortran Intel #4 2.692.702441327  0% 0% 0% 100%
1.3C gcc #5 3.403.403641261  1% 0% 1% 100%
1.3Haskell GHC #2 3.603.602,736979  2% 0% 1% 100%
1.5Ada 2005 GNAT #5 4.104.111,4962186  1% 0% 0% 100%
1.6C++ g++ #3 4.234.231,0721286  1% 0% 1% 100%
1.6C++ g++ #2 4.434.448241105  0% 1% 1% 100%
1.7Fortran Intel #3 4.464.475081190  0% 0% 0% 100%
1.7C++ g++ 4.674.688281033  0% 1% 1% 100%
2.0Java  #4 5.375.3720,8881507  0% 1% 1% 100%
2.0Java  #5 5.445.4432,6642457  1% 1% 0% 100%
2.2Fortran Intel 5.985.985081155  0% 1% 1% 100%
2.3C gcc #4 6.066.073641221  1% 1% 1% 100%
2.3C++ g++ #4 6.246.253601266  1% 0% 1% 100%
2.4Scala #3 6.466.4727,2041053  0% 1% 1% 100%
2.4C# Mono #2 6.536.5420,1921180  1% 0% 0% 100%
2.7C gcc 7.267.263641185  1% 0% 1% 100%
2.7Go 7.267.271,0281036  1% 0% 0% 100%
2.8Clojure #6 7.657.6660,6721653  0% 1% 1% 100%
2.9Lisp SBCL #6 7.847.848,6441751  1% 0% 0% 100%
3.1Java  #2 8.378.3720,3321240  1% 1% 1% 100%
3.1F# Mono 8.428.4221,276978  1% 0% 0% 100%
3.4Dart 9.179.1765,5241386  1% 1% 0% 100%
3.5C# Mono #4 9.559.5646,6561505  1% 0% 1% 100%
3.9OCaml #6 10.5210.53201,7801161  0% 0% 0% 100%
4.0Scala 10.7110.7127,0961080  0% 0% 0% 100%
4.0Lisp SBCL #3 10.7310.738,6561579  1% 0% 0% 100%
4.1Pascal Free Pascal #4 11.1311.1381112  1% 0% 0% 100%
4.3Clojure #5 11.6111.6264,6841839  0% 0% 1% 100%
4.4Ada 2005 GNAT 11.7711.781,4921346  1% 0% 1% 100%
5.0OCaml #3 13.4113.423,1241042  0% 0% 0% 100%
6.4Racket #3 17.2217.2324,5841276  0% 1% 0% 100%
6.9Lisp SBCL 18.5718.588,6561419  1% 0% 0% 100%
7.1Lisp SBCL #2 19.1819.198,6561617  0% 0% 1% 100%
9.1JavaScript V8 #2 24.5224.5545,284923  0% 1% 0% 100%
11Erlang HiPE #2 29.0729.0911,9161164  0% 0% 0% 100%
13Hack #4 34.4534.47303,9641109  1% 0% 0% 100%
16JavaScript V8 42.7342.759,660791  1% 1% 0% 100%
17Lua 44.5944.601,4801049  0% 0% 0% 100%
18Smalltalk VisualWorks 47.2447.2541,2841315  0% 0% 0% 100%
19Racket 49.9349.9621,4241054  0% 1% 1% 100%
21Hack #3 56.7456.77303,9521029  1% 0% 0% 100%
22Erlang HiPE 58.1058.1311,9241039  0% 0% 0% 100%
25Hack #2 68.3268.3555,6081003  1% 0% 0% 100%
36Perl 96.4396.46100,036838  0% 0% 0% 100%
56Ruby #5 144.98149.947,512987  1% 1% 0% 100%
56PHP #3 148.29151.553,3321030  0% 0% 0% 100%
58Ruby #4 149.87155.05243,360904  2% 1% 1% 100%
59Python 3 156.10160.135,572792  1% 0% 0% 100%
63Python 3 #2 165.35170.105,580788  1% 0% 0% 100%
76Ruby #2 203.65203.72202,920732  0% 0% 1% 100%
82Ruby JRuby 216.29220.27650,292760  0% 1% 1% 100%
99Perl #4 267.46267.562,352934  0% 0% 0% 100%
146Perl #2 6 min6 min2,356886  0% 0% 0% 100%
160PHP #2 7 min7 min3,3361006  0% 0% 0% 100%
Haskell GHC Bad Output1421
Haskell GHC #4 Bad Output1413
"wrong" (different) algorithm / less comparable programs
0.7Perl #5 1.881.8824,9521113
1.7C gcc #2 4.664.664921169
5.0Haskell GHC #3 13.6013.612,1121408
missing benchmark programs
Rust No program

 fasta benchmark : Generate and write random DNA sequences

diff program output N = 1000 with this 10KB 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.

Each program should

We'll use the generated FASTA file as input for other benchmarks (reverse-complement, k-nucleotide).

Random DNA sequences can be based on a variety of Random Models (554KB pdf). You can use Markov chains or independently distributed nucleotides to generate random DNA sequences online.

Revised BSD license

  Home   Conclusions   License   Play