binary-trees First a few simple programs. Then optimisations, multicore parallelism, [pdf] vector parallelism. Last hand-written vector instructions and "unsafe" programs. source secs mem gz Erlang 10.90 482,520 426 Pharo Smalltalk 35.00 329,088 673 × source secs mem gz cpu secs cpu load 1.0 C++ g++ #7 0.96 201,536 896 3.35 84% 100% 83% 84% 1.1 Rust #5 1.08 198,656 771 3.77 84% 99% 83% 85% 1.2 C++ g++ #5 1.15 200,660 891 4.08 87% 86% 98% 86% 1.3 Rust #2 1.22 199,684 729 4.29 85% 86% 85% 98% 1.4 Rust #4 1.33 187,948 765 4.80 88% 88% 99% 88% 1.5 Rust #3 1.40 188,740 762 5.06 89% 87% 99% 87% 1.6 C gcc #2 1.57 169,216 816 4.48 100% 63% 56% 67% 1.7 C++ g++ #9 1.65 136,064 815 4.55 57% 53% 68% 100% 2.0 C gcc #3 1.92 134,400 842 4.70 48% 44% 55% 100% 2.0 C++ g++ #6 1.92 266,112 851 4.74 62% 53% 45% 87% 2.1 Rust 2.05 132,992 760 7.21 83% 96% 86% 87% 2.2 Free Pascal #5 2.10 132,608 959 5.00 54% 100% 47% 39% 2.2 Free Pascal #6 2.10 132,608 967 5.03 100% 54% 39% 47% 2.2 Free Pascal #7 2.15 132,608 1010 5.15 99% 41% 45% 54% 2.3 Classic Fortran #2 2.17 140,416 1155 6.84 77% 71% 81% 86% 2.3 Haskell GHC #8 2.19 232,788 807 5.28 73% 53% 51% 66% 2.3 C++ g++ #8 2.22 266,112 826 5.26 55% 64% 87% 34% 2.4 C++ g++ #3 2.25 265,600 951 5.11 54% 100% 40% 35% 2.5 Haskell GHC #7 2.39 262,800 817 6.02 61% 70% 65% 56% 2.7 Java #7 2.59 1,718,620 841 8.08 91% 74% 74% 73% 2.8 C++ g++ 2.68 2,068,612 760 9.34 86% 93% 86% 84% 3.1 Lisp SBCL #3 3.00 660,620 938 7.41 58% 84% 61% 45% 3.8 OCaml #2 3.59 216,628 759 10.35 43% 76% 84% 85% 4.2 Haskell GHC #6 4.06 236,896 601 7.72 44% 42% 56% 49% 4.7 Java #4 4.46 1,957,564 846 5.19 9% 32% 69% 6% 4.8 C# .NET #7 4.61 1,552,024 706 15.20 77% 92% 80% 82% 4.9 C# .NET #2 4.73 1,619,108 717 15.24 80% 90% 77% 77% 5.0 Erlang #2 4.81 478,992 485 13.06 90% 62% 71% 74% 5.1 Java #3 4.90 2,032,184 546 5.67 6% 57% 46% 5% 5.2 Java #6 5.02 2,065,280 535 5.79 57% 5% 44% 10% 5.3 C# .NET #3 5.08 1,955,472 688 16.49 77% 80% 79% 89% 5.3 Java #2 5.11 2,064,188 558 5.83 6% 7% 14% 88% 5.5 C# .NET 5.23 2,107,524 668 16.88 76% 90% 79% 78% 5.6 F# .NET #7 5.32 1,742,212 527 16.10 72% 83% 76% 73% 7.3 Haskell GHC #3 6.96 682,624 544 15.87 55% 64% 51% 57% 7.5 Chapel #4 7.13 477,824 489 26.17 99% 89% 89% 89% 7.7 Haskell GHC #5 7.37 671,276 567 15.63 48% 53% 70% 40% 8.1 OCaml #5 7.80 221,952 468 7.80 0% 0% 1% 100% 8.8 Chapel #3 8.47 300,928 494 25.54 99% 72% 74% 56% 9.0 C gcc #5 8.66 351,232 914 31.56 98% 85% 89% 92% 9.3 Node.js 8.91 1,393,184 717 33.54 94% 94% 94% 94% 9.5 Node.js #6 9.07 1,348,960 752 31.26 90% 86% 83% 87% 9.5 Racket #2 9.11 327,096 422 9.11 0% 100% 0% 0% 10 Lisp SBCL 9.57 643,680 595 9.57 0% 100% 0% 0% 11 Dart #7 10.37 792,356 869 23.17 53% 58% 55% 56% 11 F# .NET 10.44 1,248,320 517 12.58 11% 45% 26% 38% 11 Erlang 10.90 482,520 426 11.11 7% 61% 33% 1% 12 Dart #4 11.27 575,648 1394 24.06 55% 45% 60% 54% 12 Ada 2012 GNAT #3 11.28 529,408 1275 37.11 81% 80% 81% 87% 12 Dart #6 11.61 443,064 488 15.63 11% 98% 11% 14% 13 Haskell GHC #2 12.13 264,704 498 13.80 31% 60% 17% 6% 13 Dart #5 12.56 488,812 1023 28.71 54% 58% 55% 62% 13 Haskell GHC 12.68 671,616 500 14.44 9% 13% 77% 14% 14 Swift #3 13.65 705,408 868 44.22 66% 98% 83% 77% 14 Swift #2 13.66 705,408 822 44.06 70% 82% 95% 76% 15 Go #2 14.17 624,780 672 56.29 99% 99% 99% 99% 15 Julia #4 14.17 509,044 378 43.67 75% 74% 72% 85% 15 Swift #5 14.19 736,000 813 42.12 61% 94% 68% 74% 15 Julia #3 14.58 660,940 640 40.85 75% 72% 71% 60% 16 Go #5 14.87 425,960 957 58.15 98% 98% 97% 98% 16 Go #3 14.91 326,508 806 58.00 98% 96% 98% 96% 16 Racket 15.10 543,632 482 15.09 0% 99% 0% 0% 16 PHP #7 15.58 948,608 767 56.00 88% 89% 93% 89% 18 VW Smalltalk #3 16.93 375,808 932 38.02 50% 62% 82% 30% 18 Node.js #7 17.30 1,067,648 458 29.17 36% 59% 39% 34% 19 Julia #2 17.96 659,396 430 36.38 65% 58% 33% 45% 19 PHP #4 18.34 918,528 786 56.94 73% 82% 70% 85% 20 Ruby yjit #5 19.08 521,972 1016 54.19 98% 61% 61% 64% 20 Julia #5 19.62 464,332 396 66.68 88% 87% 84% 80% 21 Swift #4 19.79 705,408 772 63.20 78% 74% 99% 67% 21 Swift 20.57 735,360 720 61.12 72% 63% 68% 94% 22 C gcc 21.32 264,064 660 21.32 100% 0% 0% 0% 22 Dart #3 21.48 7,872,504 1219 54.28 60% 60% 69% 64% 23 C++ g++ #2 21.96 265,856 514 21.96 0% 0% 100% 0% 24 Ada 2012 GNAT 23.25 266,240 896 23.24 100% 0% 0% 0% 29 PHP #6 27.48 805,532 877 91.38 79% 89% 87% 77% 29 Go #6 27.90 404,096 618 29.26 74% 4% 23% 2% 33 Classic Fortran 31.78 525,824 780 31.77 100% 0% 0% 0% 33 Go 32.01 243,192 488 59.78 45% 50% 46% 44% 34 Go #7 32.52 248,604 531 61.47 45% 50% 51% 43% 35 PHP #5 33.17 805,512 1048 84.83 24% 77% 86% 68% 36 Python 3 #5 34.55 274,944 669 123.08 81% 89% 99% 87% 36 Python 3 #4 34.68 277,504 481 127.31 89% 99% 89% 89% 37 Python 3 35.50 277,632 597 126.38 86% 87% 95% 87% 40 VW Smalltalk 37.93 375,552 717 37.93 2% 97% 0% 0% 42 Perl #6 40.21 760,192 800 148.50 90% 90% 99% 90% 48 PHP #3 46.07 921,600 434 46.07 3% 96% 0% 0% 49 Ruby yjit #4 47.23 478,464 371 47.22 97% 0% 2% 0% 51 Lua #4 48.65 956,672 670 180.27 97% 91% 91% 91% 51 Ruby yjit 48.86 478,592 383 48.85 100% 0% 0% 0% 51 Ruby yjit #2 48.90 524,800 385 48.89 43% 0% 56% 0% 52 Python 3 #3 49.75 672,384 1247 143.18 71% 92% 62% 61% 52 Ruby yjit #3 49.82 517,080 407 49.81 100% 0% 0% 0% 55 Perl #5 52.18 1,048,704 805 189.88 87% 100% 88% 88% 65 PHP 61.97 748,788 457 61.97 13% 86% 0% 0% 66 PHP #2 63.25 748,792 429 63.24 0% 100% 0% 0% 83 Perl #4 79.54 2,519,560 769 287.74 88% 95% 88% 89% 87 Lua #3 83.71 809,856 690 167.26 59% 47% 40% 52% 111 Python 3 #2 105.82 272,384 344 105.81 0% 0% 100% 0% 115 Perl #3 110.37 2,200,700 655 6 min 74% 93% 73% 98% 148 Lua #2 141.55 956,672 418 141.52 100% 0% 0% 0% 276 Perl 263.97 599,424 401 263.95 0% 96% 3% 0% 352 Matz's Ruby #5 5 min 1,559,164 1016 17 min 74% 73% 96% 72% 619 Matz's Ruby #3 9 min 840,268 407 9 min 100% 0% 0% 0% Matz's Ruby #4 12 min 1,559,040 371 12 min 96% 3% 0% 0% Matz's Ruby 13 min 1,558,912 383 13 min 25% 0% 0% 74% Matz's Ruby #2 13 min 1,559,040 385 13 min 94% 1% 0% 4% Ada 2012 GNAT #4 Failed C# .NET #8 Make Error C++ g++ #4 Make Error Swift #9 Make Error hand-written vector instructions | "unsafe" × source secs mem gz cpu secs cpu load 5.2 Racket #4 5.00 418,536 861 9.56 56% 43% 51% 42% 6.4 Racket #3 6.14 223,504 480 6.14 0% 0% 100% 0% by secs by mem by gz by cpu secs