mandelbrot benchmark N=16,000

Each chart bar shows how many times more Memory, one ↓ mandelbrot program used, compared to the program that used least Memory.

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.

    sortsort sort
  ×   Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
1.0Pascal Free Pascal #3 75.4475.478530  0% 1% 100% 0%
100C gcc #2 47.3447.35800400  1% 0% 100% 1%
120OCaml #6 54.9855.00960444  1% 0% 100% 1%
188C++ g++ #3 83.3483.361,504414  100% 0% 1% 0%
241Ada 2005 GNAT #2 53.1153.131,928572  0% 1% 100% 1%
534PHP 20 min20 min4,268443  23% 18% 35% 27%
687OCaml 54.8913.785,492710  100% 100% 100% 100%
888Ruby #3 31 min31 min7,104307  20% 25% 44% 13%
1,311Python 3 #2 28 min7 min10,488777  100% 99% 99% 99%
2,587Racket #2 85.6085.5920,696585  0% 29% 0% 72%
2,729Racket 107.53107.5221,832517  1% 0% 100% 0%
3,492C gcc 23.465.8827,932822  100% 100% 100% 100%
3,675C gcc #6 24.216.0729,396879  100% 100% 100% 100%
3,756Pascal Free Pascal #5 134.9633.8230,044829  100% 100% 100% 100%
3,799C gcc #4 24.076.0530,392799  100% 100% 100% 100%
3,890Go #6 47.1911.8231,116700  100% 100% 100% 100%
3,890Racket #3 75.3675.3431,120797  0% 1% 40% 60%
3,895Pascal Free Pascal #4 68.1417.0731,160748  100% 100% 100% 100%
3,909Go 51.9713.0431,272823  100% 100% 100% 100%
3,969Go #3 25.506.4131,748894  100% 100% 99% 100%
4,001Ada 2005 GNAT #3 24.146.0932,0041805  99% 99% 100% 99%
4,030C gcc #9 19.775.1332,240694  95% 96% 100% 96%
4,057Pascal Free Pascal 80.5930.3432,456820  91% 40% 95% 41%
4,065C gcc #3 24.236.0832,516763  100% 100% 100% 100%
4,073Fortran Intel #5 56.8656.8832,580508  1% 1% 0% 100%
4,111C gcc #7 24.246.0932,888994  100% 100% 100% 100%
4,113C++ g++ #6 28.087.0532,9041035  100% 100% 100% 100%
4,173C++ g++ #5 36.1236.1333,384590  1% 100% 0% 0%
4,203C++ g++ #9 33.018.5833,620726  95% 95% 100% 95%
4,206C++ g++ #8 33.0712.2333,648742  99% 36% 37% 100%
4,216C++ g++ #2 38.6538.6633,728687  0% 0% 100% 1%
4,423Go #2 41.5110.4135,380837  100% 100% 100% 100%
4,737C++ g++ #7 24.406.1337,8921017  100% 100% 100% 100%
4,917Java  43.0543.0139,336665  2% 99% 0% 1%
5,000C# Mono #2 56.2456.2640,000484  100% 1% 1% 1%
5,034Python 3 #5 34 min8 min40,268449  100% 100% 100% 100%
5,151Haskell GHC #2 45.8111.4941,208782  100% 100% 100% 100%
5,307Python 3 #7 15 min239.6042,456686  100% 100% 100% 100%
5,425Perl 51 min12 min43,400579  100% 100% 100% 100%
5,699Scala #2 51.9051.8345,592454  0% 1% 100% 0%
5,761Lisp SBCL #3 46.5718.1846,084888  92% 40% 93% 32%
6,127F# Mono #2 48.3113.2649,0121043  86% 95% 92% 92%
6,952Rust #2 24.326.1555,6161080  99% 99% 99% 100%
6,959Lisp SBCL 28.537.9055,6722459  82% 100% 98% 83%
7,635Fortran Intel #4 49.0818.7861,076611  94% 41% 93% 34%
7,830Ruby #5 32 min8 min62,6361019  100% 100% 100% 100%
8,357Scala 51.1812.9766,852724  98% 98% 99% 100%
8,645Ruby #4 31 min31 min69,156866  21% 29% 31% 20%
8,699Racket #4 73.7018.6569,588796  99% 99% 100% 99%
10,103C# Mono #3 45.2011.5180,820701  99% 98% 98% 98%
10,117C# Mono 46.0711.7380,932798  98% 98% 100% 98%
10,267F# Mono #3 44.5311.3682,136800  98% 100% 98% 98%
10,405C# Mono #6 31.598.1183,236986  100% 97% 97% 97%
10,614C# Mono #4 31.578.1084,908872  99% 98% 97% 97%
10,701F# Mono #4 34.989.1385,608869  96% 96% 97% 95%
11,122Java  #6 27.967.1688,976802  97% 97% 99% 97%
11,124Java  #2 24.246.2788,992796  96% 97% 97% 98%
11,150Scala #5 43.6815.8889,196589  87% 71% 67% 51%
11,151Java  #3 45.5011.5389,208903  100% 99% 98% 98%
11,640Scala #4 27.977.2093,120786  97% 100% 97% 96%
11,941Dart 56.8821.0095,528901  98% 37% 99% 37%
14,405PHP #3 20 min5 min115,240863  100% 100% 100% 100%
14,420Clojure #5 51.5350.13115,3601077  49% 5% 47% 3%
14,939Hack 248.08248.20119,512441  24% 27% 23% 28%
14,988Hack #2 80.8480.86119,900458  100% 1% 0% 1%
16,511Clojure #6 52.6614.36132,0881077  90% 91% 91% 95%
16,946Ruby #2 33 min8 min135,564925  99% 99% 100% 99%
19,122Clojure #7 32.409.02152,9761195  89% 86% 97% 88%
37,548Ruby #6 37 min9 min300,384909  95% 95% 95% 95%
82,536Ruby JRuby #3 18 min18 min660,288307  21% 30% 33% 19%
94,785Ruby JRuby #2 1h 53 min29 min758,280925  99% 99% 98% 99%
95,368Ruby JRuby #4 55 min14 min762,944866  98% 98% 98% 98%
164,054Erlang #2 31 min8 min1,312,428613  99% 99% 99% 99%
171,306Erlang HiPE #2 8 min131.961,370,444613  95% 95% 96% 95%
199,654Ruby JRuby #5 1h 02 min16 min1,597,2281019  98% 98% 98% 98%
205,402Erlang 32 min8 min1,643,216534  98% 98% 98% 98%
214,370Erlang HiPE 8 min142.801,714,956534  92% 92% 94% 92%
Fortran Intel #2 Bad Output813
Fortran Intel #3 Bad Output754
Fortran Intel Bad Output485
Hack #3 Failed864
Pascal Free Pascal #2 Make Error817
Ruby JRuby #6 Failed909
Scala #3 Failed796
"wrong" (different) algorithm / less comparable programs
2,128C gcc #5 7.341.8517,0201026
3,683C++ g++ 10.522.6429,4641239
4,062C gcc #8 16.934.2432,496859
6,769Python 3 #6 119.8130.7854,1521380

 mandelbrot benchmark : Generate Mandelbrot set portable bitmap file

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

More specifically:

cmp program output N = 200 with this 5KB 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.

Mandlebrot output N=200,converted to PNG

Each program should plot the Mandelbrot set [-1.5-i,0.5+i] on an N-by-N bitmap. Write output byte-by-byte in portable bitmap format.

For more information see Eric W. Weisstein, "Mandelbrot Set." From MathWorld--A Wolfram Web Resource.
http://mathworld.wolfram.com/MandelbrotSet.html

Thanks to Greg Buchholz for this benchmark.

Revised BSD license

  Home   Conclusions   License   Play