chameneos-redux benchmark N=6,000,000

Each chart bar shows how many times slower, one ↓ chameneos-redux 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 #5 2.540.645682863  98% 100% 100% 100%
1.2Lisp SBCL #3 3.000.7936,9882907  92% 97% 99% 92%
3.3Ada 2005 GNAT #2 8.242.113,6566001  96% 96% 99% 100%
4.6C++ g++ #5 11.302.969081994  100% 100% 92% 92%
4.9C++ g++ #2 11.133.139122016  100% 65% 93% 99%
6.9Java  5.004.4231,4561770  40% 43% 12% 17%
8.0Haskell GHC 9.275.1710,604989  79% 100% 1% 1%
8.2Java  #4 18.225.2726,3241607  86% 98% 66% 97%
9.2Haskell GHC #4 11.845.918,588989  100% 100% 2% 1%
12Java  #3 26.347.8456,0081267  97% 99% 63% 78%
12Go #5 7.987.98760957  0% 1% 100% 0%
20C gcc #2 41.7612.955841663  86% 72% 85% 90%
20Java  #2 39.2213.0242,0041429  84% 74% 79% 69%
21Scala #2 37.4313.5758,4641171  71% 65% 75% 69%
25Ada 2005 GNAT #5 58.3516.091,6202906  93% 93% 93% 93%
34C# Mono 70.1721.6622,5721400  86% 88% 78% 81%
64Ruby JRuby 95.7041.38647,768928  59% 59% 57% 58%
86Erlang HiPE 128.8855.0414,008734  61% 62% 57% 59%
170Rust 228.35109.1139,9081692  43% 61% 59% 38%
223Clojure 166.05143.09390,9921331  30% 29% 29% 30%
236Ruby 223.34151.565,448920  26% 37% 37% 25%
250Racket #2 160.46160.44105,184842  1% 1% 1% 100%
392Python 3 #2 6 min251.834,392866  37% 37% 32% 32%
417Racket 268.41268.3878,364791  1% 0% 100% 1%
439OCaml 7 min282.324,1161279  40% 37% 36% 40%
747Perl #4 11 min8 min6,836785  34% 35% 34% 34%
1,228OCaml #3 20 min13 min3,2041146  35% 35% 35% 35%
C++ g++ Make Error2449
Scala Failed1271
missing benchmark programs
Dart No program
F# Mono No program
Fortran Intel No program
Pascal Free Pascal No program
PHP No program

 chameneos-redux benchmark : Symmetrical thread rendezvous requests

You can write your own program for this task and contribute to the benchmarks game by following these general instructions.

More specifically:

ndiff program output N = 600 with this output file to check your program output has the correct format 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.

The text-part and spelled-out numbers in the program output should match the expected output exactly. Thread scheduling may cause small differences in the other numbers, so program output is checked with ndiff -fields 2-10

Each program should

The chameneos benchmark is an adaptation of "Chameneos, a Concurrency Game for Java, Ada and Others" 100KB pdf (which includes example implementations in Java, Ada and C).

Programs may use pre-emptive kernel threads or pre-emptive lightweight threads; but programs that use non pre-emptive threads (coroutines, cooperative threads) and any programs that use custom schedulers, will be listed as interesting alternative implementations. Briefly say what concurrency technique is used in the program header comment.

Revised BSD license

  Home   Conclusions   License   Play