The Computer Language
24.11 Benchmarks Game

reverse-complement

These are crowd sourced programs, contributed to the project by an ever-changing self-selected group.

We include both un-optimised programs and heavily optimised programs (look at the gz source code size). We include both single-thread programs and multi-thread programs (look at the cpu secs and cpu load). We include [pdf] vector parallelism and even hand-written vector instructions. How the programs are written matters!

Always look at the source code.

× source secs mem gz cpu secs cpu load
1.0 C gcc #9 0.48 500,032 1551 0.76 41% 20% 22% 79%
1.2 C# .NET #9 0.59 733,932 2641 1.37 70% 66% 22% 75%
1.9 Chapel #9 0.92 1,057,024 1260 2.65 98% 64% 63% 63%
2.0 C gcc #6 0.96 675,260 828 1.36 26% 99% 2% 17%
2.0 Rust #2 0.98 995,200 1332 1.62 66% 21% 56% 23%
2.1 Rust #3 0.98 995,200 1105 1.68 42% 23% 58% 46%
2.2 C gcc #2 1.06 994,536 757 1.58 86% 19% 13% 30%
3.2 C gcc #5 1.53 994,108 654 1.53 100% 0% 0% 0%
3.2 C# .NET #7 1.54 927,984 1312 4.25 36% 56% 90% 94%
3.3 C# .NET #6 1.55 1,027,196 1627 3.76 18% 54% 96% 75%
3.5 Julia #7 1.65 1,024,148 531 1.76 4% 90% 11% 0%
3.8 Chapel #3 1.81 2,121,216 709 3.18 92% 26% 25% 34%
3.8 Chapel #5 1.83 2,133,376 554 3.18 94% 25% 24% 32%
4.0 Go #6 1.91 1,244,508 1340 3.40 72% 17% 31% 59%
4.2 Julia #9 2.00 1,220,680 456 2.11 96% 8% 1% 2%
4.6 Go #2 2.19 800,640 614 2.29 0% 16% 0% 89%
4.8 OCaml #3 2.28 19,676 1361 5.77 65% 65% 58% 63%
5.2 Go #3 2.48 800,384 609 2.57 94% 3% 1% 5%
5.3 C# .NET #5 2.53 1,025,008 1620 3.83 18% 37% 1% 93%
6.3 Ada 2012 GNAT #2 2.99 822,216 3285 3.82 0% 0% 42% 85%
6.6 C# .NET 3.14 583,252 1130 3.18 3% 57% 42% 0%
6.6 Java  #6 3.15 2,032,996 760 3.79 33% 8% 0% 78%
6.9 C++ g++ #6 3.30 1,517,824 1827 4.38 22% 32% 66% 13%
7.0 Intel Fortran 3.33 986,304 1026 3.33 0% 0% 100% 0%
8.0 Free Pascal #2 3.81 525,052 773 3.81 0% 0% 0% 100%
8.6 Python 3 #5 4.09 1,500,716 960 7.41 89% 0% 54% 38%
9.9 Java #5 4.72 1,097,732 1115 4.84 29% 10% 60% 3%
10 Python 3 #3 4.86 507,712 803 4.86 0% 100% 0% 0%
11 Lisp SBCL 5.46 1,494,784 911 5.46 100% 0% 0% 0%
12 Java #4 5.65 1,891,656 656 5.77 95% 3% 2% 2%
12 Perl #4 5.76 998,608 268 5.76 100% 0% 0% 0%
12 Ruby yjit #4 5.88 2,510,920 608 11.51 32% 86% 25% 53%
14 C++ g++ 6.52 980,156 599 6.51 0% 1% 100% 0%
14 Perl #3 6.77 1,495,228 295 6.76 1% 1% 99% 0%
15 Python 3 #6 7.38 2,484,372 821 10.89 28% 46% 19% 53%
17 PHP #3 8.13 536,024 452 12.47 4% 55% 63% 29%
18 C# .NET #3 8.47 1,380,908 934 13.21 43% 27% 49% 36%
19 Dart #5 8.95 1,994,744 942 12.12 31% 13% 67% 23%
19 Ruby yjit #3 8.95 4,235,052 490 17.34 97% 23% 25% 48%
19 OCaml #2 9.27 909,056 426 9.27 0% 99% 0% 0%
20 Matz's Ruby #3 9.49 3,467,256 490 17.96 76% 50% 33% 30%
21 Python 3 #2 10.08 1,788,136 440 10.08 100% 0% 0% 0%
21 PHP 10.22 1,488,780 323 10.22 47% 52% 0% 0%
22 Python 3 10.29 1,986,440 484 10.29 0% 99% 0% 0%
26 PHP #2 12.21 1,786,608 288 12.20 73% 26% 0% 0%
28 Python 3 #4 13.41 4,002,688 343 13.41 100% 0% 0% 0%
28 Ada 2012 GNAT 13.45 528,504 943 13.45 100% 0% 0% 0%
30 Ruby yjit #5 14.12 1,623,336 301 14.11 0% 100% 0% 0%
38 Ruby yjit 18.31 5,141,976 521 35.91 40% 94% 56% 4%
40 Dart 19.20 1,001,112 651 20.10 50% 51% 1% 2%
50 Matz's Ruby #2 23.61 688,216 272 23.61 58% 41% 0% 0%
50 Java #7 23.98 1,037,708 1654 6.26 4% 6% 12% 4%
58 Ruby yjit #2 27.45 1,001,920 272 27.45 0% 100% 0% 0%
61 Julia #2 29.29 1,951,468 464 29.83 35% 64% 2% 0%
79 C++ g++ #5 37.59 771,632 704 37.58 72% 27% 0% 0%
84 F# .NET 39.89 3,000,744 603 41.18 9% 54% 1% 38%
85 Racket 40.68 2,047,232 560 40.68 0% 100% 0% 0%
86 Lua #2 41.12 2,654,652 560 41.10 0% 100% 0% 0%
88 Lua #5 41.96 2,169,636 758 41.96 100% 0% 0% 0%
90 Intel Fortran #2 42.90 769,748 778 42.89 0% 100% 0% 0%
103 Lua #4 49.35 1,030,016 600 49.33 0% 100% 0% 0%
122 Dart #3 58.10 6,394,552 571 64.47 54% 43% 9% 3%
191 Dart #2 91.20 6,406,136 575 99.37 46% 47% 10% 4%
  Erlang 26 min 2,180,832 1309 30 min 41% 21% 15% 35%
C++ g++ #3 Bad Output
Dart #4 Bad Output
Erlang #4 Timed Out
Erlang #3 Timed Out
F# .NET #4 Timed Out
F# .NET #5 Timed Out
Go #5 Bad Output
Go Failed
Java #3 Bad Output
Node.js #7 Bad Output
Lisp SBCL #2 Failed
Matz's Ruby Failed
Matz's Ruby #5 Failed
Matz's Ruby #4 Failed
VW Smalltalk Bad Output
 
 
  * possible hand-written vector instructions | "unsafe"
 
× source secs mem gz cpu secs cpu load
0.9 * C gcc #7 0.44 499,992 1899 0.59 76% 11% 36% 14%
1.1 * Rust 0.53 498,816 2762 0.83 19% 20% 18% 100%
1.5 * C++ g++ #2 0.74 499,916 2099 0.74 0% 0% 100% 2%
4.1 * Swift 1.95 798,228 1293 2.39 40% 4% 1% 78%
4.7 * OCaml 2.25 19,676 1372 5.09 57% 59% 56% 53%
6.5 * Haskell GHC #4 3.08 507,008 1047 3.15 2% 55% 20% 25%
7.7 * C gcc #4 3.70 500,452 716 3.69 1% 11% 1% 89%
13 * Haskell GHC #2 6.37 3,533,056 998 6.48 0% 35% 53% 12%
19 * Racket #2 9.06 784,116 1038 9.06 0% 100% 0% 0%
32 * Node.js #2 15.44 731,804 1228 16.09 47% 31% 4% 22%