/mobile Handheld Friendly website

 regex-dna benchmark ≈50MB N=5,000,000

Each chart bar shows how many times slower, one ↓ regex-dna 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.0C gcc 6.202.59287,9002579  46% 70% 51% 74%
1.5C++ g++ #2 5.383.83171,652695  1% 65% 76% 2%
1.8C++ g++ #4 13.824.6995,1761759  90% 97% 51% 59%
2.1C++ g++ 5.345.35186,252648  1% 0% 1% 100%
2.5Ada 2005 GNAT #6 19.656.4793,0763740  67% 70% 72% 96%
2.7Ada 2005 GNAT #5 19.447.1098,2203492  64% 56% 57% 98%
3.1C gcc #4 23.847.9391,5521525  63% 66% 72% 100%
3.4Haskell GHC #2 33.458.76200,3921518  96% 93% 96% 98%
3.5Clojure #4 28.529.02634,928707  72% 75% 72% 97%
3.5Java  #5 26.449.20713,236929  80% 66% 77% 65%
3.7PHP #4 26.749.65150,664832  60% 53% 95% 70%
4.2PHP 12.1410.77215,748788  62% 47% 57% 82%
4.2Python 3 23.8111.01248,260478  37% 72% 45% 64%
4.8Java  #2 39.1612.47710,7481534  79% 70% 74% 92%
5.3Perl #2 34.5613.84140,296527  36% 77% 59% 78%
6.3Scala #2 36.3416.40864,252668  46% 68% 41% 68%
7.7Ruby #3 42.9019.90271,304501  37% 41% 100% 38%
7.7C++ g++ #3 30.8419.98177,740844  94% 1% 60% 1%
8.1Lisp SBCL #3 43.9420.90868,0441948  40% 92% 41% 38%
8.1Java  #7 21.2520.93558,5001284  97% 2% 4% 1%
8.6Go #8 72.3422.25630,192785  77% 85% 75% 89%
9.0Ruby JRuby #3 62.6023.382,049,368501  61% 60% 63% 84%
9.2Ruby JRuby #2 62.9923.752,003,700417  57% 63% 82% 64%
9.2Python 3 #5 23.9623.97247,792424  0% 1% 1% 100%
9.4Java  #4 25.8224.24725,364921  92% 6% 3% 7%
9.7F# Mono #3 76.2525.062,337,488870  68% 72% 73% 92%
9.7F# Mono 82.2425.09958,276639  86% 82% 77% 84%
10Clojure #3 49.0125.90901,928710  29% 60% 62% 40%
10PHP #3 26.4826.50212,432459  0% 0% 0% 100%
11Ruby #6 28.2728.28162,528442  0% 0% 0% 100%
12C gcc #2 30.1830.20125,8921099  0% 1% 0% 100%
12C# Mono #6 78.5031.81376,872638  67% 53% 51% 77%
13PHP #2 34.5534.57221,796449  0% 1% 1% 100%
14Scala 39.0135.12747,980611  18% 61% 5% 29%
14Ruby #5 35.9435.95103,552343  0% 0% 100% 0%
15Racket 39.8639.85669,612527  1% 1% 1% 100%
16Ruby JRuby #5 47.6742.28909,128343  13% 90% 5% 7%
17Ruby #2 42.8442.86348,968417  15% 19% 21% 46%
19Go 151.2148.46666,372733  75% 74% 74% 91%
20Erlang HiPE #6 185.5452.36208,5721058  82% 97% 95% 80%
21Ruby JRuby #6 59.2053.68927,640442  32% 5% 43% 31%
22Ruby 57.2757.29319,148308  0% 0% 0% 100%
28Go #7 72.5671.81512,752652  1% 42% 1% 59%
29C# Mono #2 76.3276.35340,588594  1% 55% 0% 44%
31F# Mono #2 79.2879.331,756,272413  1% 99% 0% 1%
32C# Mono 81.6581.701,002,388624  100% 1% 0% 0%
33Ruby JRuby 93.4585.072,101,424308  14% 89% 4% 5%
33Perl #4 86.1886.21189,272440  49% 0% 0% 51%
Dart Failed632
Dart #2 Timed Out5 min648
Erlang HiPE Timed Out10 min622
Java  #6 Failed1410
Lisp SBCL Timed Out10 min591
OCaml #4 Failed1050
OCaml #2 Failed615
OCaml Failed1502
OCaml #3 Failed1014
Racket #2 Bad Output536
Scala #3 Failed633
Scala #4 Failed723
"wrong" (different) algorithm / less comparable programs
1.1Erlang HiPE #7 8.212.96261,9921198
1.3Java  #3 8.603.34257,5362084
1.3Perl #7 4.733.41140,028567
1.9Perl #6 4.974.98188,520477
7.9Pascal Free Pascal 20.4920.50113,9161199
missing benchmark programs
Fortran Intel No program
Pascal Free Pascal No program
Rust No program

 regex-dna benchmark : Match DNA 8-mers and substitute nucleotides for IUB codes

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

Revised BSD license

  Home   Conclusions   License   Play