The Computer Language
24.11 Benchmarks Game

spectral-norm

First, here are half-a-dozen naive un-optimised single-thread #8 programs transliterated lowest-common-denominator style into different programming languages from the same original —

  source secs mem gz    
  Ruby yjit #8 168.99 21,120 294    
  Python 3 #8 6 min 19,440 334    
  Node.js #8 6.49 54,632 355    
  PHP #8 136.62 19,768 357    
  C gcc #8 5.40 19,772 389    
  Java #8 5.43 43,368 453    
 
 
  Here are the crowd sourced programs —  
 
 
× source secs mem gz cpu secs cpu load
1.0 Matz's Ruby #8 27 min 19,440 294 27 min 0% 0% 0% 100%
1.0 Ruby yjit #8 168.99 21,120 294 168.99 0% 0% 0% 100%
1.1 Chapel 1.46 19,620 322 5.77 100% 99% 98% 98%
1.1 Node.js 5.37 54,808 326 5.39 0% 0% 99% 1%
1.1 Ruby yjit #4 128.52 22,656 333 128.51 100% 0% 0% 0%
1.1 Matz's Ruby #4 28 min 19,936 333 28 min 0% 0% 100% 0%
1.1 Python 3 #6 5 min 19,316 334 5 min 0% 0% 0% 100%
1.1 Python 3 #8 6 min 19,440 334 6 min 0% 0% 0% 100%
1.1 Lua 78.68 19,652 335 78.68 35% 64% 0% 0%
1.2 Perl 96.60 19,688 340 96.59 100% 0% 0% 0%
1.2 Perl #5 96.53 19,688 346 96.53 0% 100% 0% 0%
1.2 Chapel #2 0.73 19,620 348 2.88 98% 98% 100% 100%
1.2 Perl #2 8 min 19,688 350 8 min 100% 0% 0% 0%
1.2 Node.js #8 6.49 54,632 355 6.50 0% 100% 0% 1%
1.2 PHP #8 136.62 19,768 357 136.59 52% 47% 0% 0%
1.3 Julia #2 1.76 261,124 377 4.80 93% 57% 68% 56%
1.3 OCaml #2 5.32 19,676 383 5.32 0% 100% 0% 0%
1.3 C gcc #8 5.40 19,772 389 5.39 100% 0% 0% 0%
1.4 PHP #2 132.92 19,768 403 132.89 46% 53% 0% 0%
1.4 Swift #8 5.33 19,568 411 5.33 0% 100% 0% 0%
1.4 Python 3 #4 90.52 19,308 415 5 min 99% 99% 99% 99%
1.4 Go 5.33 19,808 417 5.34 8% 0% 92% 0%
1.4 Node.js #7 5.36 53,724 420 5.37 14% 85% 0% 0%
1.4 Dart #8 10.88 19,436 422 10.88 94% 6% 0% 0%
1.4 Python 3 #7 97.11 19,316 425 6 min 97% 98% 98% 98%
1.5 Go #8 5.33 19,416 429 5.34 100% 0% 0% 0%
1.5 Free Pascal 11.79 19,688 429 11.79 83% 17% 0% 0%
1.5 Julia #4 1.18 232,768 435 3.66 76% 67% 77% 89%
1.5 C# .NET #8 5.41 29,720 441 5.40 6% 94% 0% 0%
1.5 Racket 29.66 77,456 452 29.65 43% 57% 0% 0%
1.5 Java  #8 5.43 43,368 453 5.49 0% 0% 1% 99%
1.6 C++ g++ 5.33 19,760 459 5.33 0% 99% 0% 0%
1.6 Dart 5.33 19,724 468 5.33 18% 0% 0% 81%
1.6 C gcc #3 1.43 19,772 470 5.70 100% 99% 100% 100%
1.7 Lisp SBCL #6 5.33 19,680 512 5.33 0% 0% 0% 100%
1.7 Erlang 63.88 63,040 513 63.98 0% 99% 0% 0%
1.8 Intel Fortran #2 2.67 19,648 520 2.66 100% 0% 0% 0%
1.9 Free Pascal #2 1.44 19,688 548 5.71 99% 99% 98% 98%
1.9 Go #4 1.45 19,808 555 5.69 98% 98% 100% 97%
1.9 Perl #4 24.86 19,688 562 97.92 98% 98% 98% 99%
2.1 Swift #3 1.43 19,440 607 5.69 100% 99% 99% 100%
2.2 Lisp SBCL 5.33 21,376 639 5.33 47% 52% 0% 0%
2.2 Intel Fortran #3 0.73 19,648 644 2.88 100% 100% 100% 100%
2.2 VW Smalltalk 49.30 55,296 649 49.29 9% 90% 0% 0%
2.2 Free Pascal #3 1.45 19,688 656 5.71 98% 99% 98% 99%
2.3 Go #2 1.50 19,808 674 5.68 95% 96% 94% 95%
2.5 Ada 2012 GNAT 5.34 19,772 725 5.34 100% 0% 0% 0%
2.5 F# .NET #4 1.57 38,892 738 5.85 97% 93% 91% 91%
2.6 Erlang #2 10.87 67,448 753 42.57 97% 98% 98% 98%
2.6 Java #3 1.57 44,160 762 5.93 98% 94% 95% 94%
2.6 Matz's Ruby #5 10 min 19,680 764 39 min 94% 91% 92% 93%
2.6 Ruby yjit #5 57.89 27,264 764 212.15 93% 89% 93% 92%
2.6 Lisp SBCL #7 1.46 19,680 769 5.64 98% 97% 97% 98%
2.7 Lisp SBCL #9 1.45 19,512 799 5.64 98% 98% 98% 98%
2.8 Rust #4 0.72 19,632 823 2.85 98% 100% 100% 100%
2.9 Perl #3 126.48 19,688 857 8 min 99% 99% 98% 98%
3.0 C# .NET #3 1.54 31,460 890 5.80 94% 95% 94% 94%
3.0 Lisp SBCL #3 1.44 19,680 893 5.64 99% 98% 98% 99%
3.1 Lisp SBCL #2 1.44 19,680 920 5.64 98% 98% 98% 99%
3.3 Java #2 1.61 43,028 956 6.08 97% 95% 94% 94%
3.4 Haskell GHC #4 1.49 19,808 994 5.70 96% 95% 98% 96%
3.4 Node.js #6 1.56 107,280 1002 5.99 95% 96% 96% 95%
3.6 VW Smalltalk #2 22.15 246,912 1054 62.81 73% 67% 70% 72%
3.7 C# .NET #2 1.52 29,864 1084 5.78 98% 94% 93% 95%
3.9 PHP 18.14 19,768 1157 72.35 99% 99% 99% 99%
4.0 Dart #2 3.26 23,772 1173 12.61 96% 97% 97% 96%
4.1 Dart #6 1.45 19,724 1202 5.70 98% 99% 98% 98%
4.1 PHP #3 35.75 19,768 1214 141.74 99% 99% 99% 99%
4.4 C++ g++ #7 1.52 19,512 1284 6.04 99% 100% 99% 100%
5.9 Ada 2012 GNAT #3 1.48 19,772 1725 5.72 96% 97% 96% 98%
C gcc #2 Make Error
F# .NET #2 Timed Out
Rust #7 Make Error
 
 
  * possible hand-written vector instructions | "unsafe"
 
× source secs mem gz cpu secs cpu load
1.4 * Haskell GHC #2 15.59 19,808 410 15.68 45% 15% 0% 40%
1.8 * Racket #2 15.09 74,900 539 15.09 11% 89% 0% 0%
2.0 * C gcc #5 0.72 19,772 576 2.85 98% 98% 100% 98%
2.2 * Racket #3 3.89 75,952 639 14.83 94% 94% 99% 94%
2.4 * F# .NET #6 0.94 39,412 697 3.41 89% 92% 88% 95%
2.6 * C# .NET #5 0.94 33,752 776 3.42 94% 93% 90% 89%
3.1 * C gcc #7 0.72 19,772 906 2.85 100% 100% 98% 100%
3.6 * C++ g++ #6 0.73 19,760 1050 2.86 100% 98% 100% 100%
3.6 * C++ g++ #5 1.33 19,760 1050 5.28 99% 99% 100% 99%
3.6 * Rust #3 0.74 19,632 1060 2.86 98% 98% 98% 98%
3.6 * Rust #5 0.72 19,632 1062 2.85 100% 100% 100% 100%
3.8 * Rust #2 0.72 19,632 1117 2.80 98% 100% 100% 98%
3.9 * Rust #6 0.72 19,632 1132 2.85 100% 98% 100% 100%
3.9 * C gcc #4 0.72 19,772 1145 2.85 100% 98% 100% 100%
4.1 * C gcc #6 0.40 19,772 1203 1.59 100% 100% 100% 100%
4.3 * Rust 0.72 19,632 1262 2.80 100% 98% 100% 98%
9.4 * Ada 2012 GNAT #4 0.78 19,772 2777 2.97 97% 96% 96% 93%