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%
50C gcc #2 47.2347.25396400  0% 1% 0% 100%
134C++ g++ #3 74.5774.601,072414  1% 0% 0% 100%
154Ada 2005 GNAT #2 57.2657.281,232572  1% 1% 100% 0%
391OCaml #6 56.3456.363,128444  93% 0% 0% 7%
532PHP 21 min21 min4,256443  28% 17% 33% 24%
819OCaml 55.8814.046,548710  100% 100% 100% 100%
939Ruby #3 31 min31 min7,508307  30% 29% 18% 25%
1,320Python 3 #2 29 min7 min10,556777  90% 100% 90% 90%
2,224Racket 102.45102.5917,788517  1% 83% 18% 1%
2,447Java  42.9842.9519,576665  1% 1% 0% 99%
2,532Racket #2 88.0488.0320,252585  0% 1% 100% 0%
2,630Racket #3 73.8573.8121,040797  5% 1% 95% 0%
2,739C# Mono #2 137.21137.2721,908484  8% 1% 89% 4%
2,975Scala #2 51.8951.8023,796454  1% 1% 4% 97%
3,593F# Mono #2 47.8313.0028,7401043  90% 97% 86% 95%
3,633C gcc #6 24.656.1829,064879  100% 100% 100% 100%
3,638C gcc #4 24.176.0729,104799  100% 100% 100% 100%
3,696C gcc 24.666.1829,568822  100% 100% 100% 100%
3,756Pascal Free Pascal #5 134.9633.8230,044829  100% 100% 100% 100%
3,875Go #6 47.0611.7931,000700  100% 100% 100% 100%
3,895Pascal Free Pascal #4 68.1417.0731,160748  100% 100% 100% 100%
3,956C gcc #3 24.086.0531,644763  100% 100% 100% 100%
3,991C gcc #9 19.445.0231,928694  96% 96% 100% 96%
3,992C gcc #7 24.246.0931,932994  100% 100% 100% 100%
3,992C++ g++ #6 28.667.1931,9361035  100% 100% 100% 100%
4,013Ada 2005 GNAT #3 22.755.7532,1041805  99% 99% 99% 99%
4,032C++ g++ #5 37.6837.7032,256590  1% 0% 0% 100%
4,041C++ g++ #2 39.5539.5632,328687  99% 1% 1% 1%
4,048C++ g++ #9 33.088.6032,384726  95% 95% 95% 100%
4,049C++ g++ #7 23.775.9732,3881017  100% 100% 100% 100%
4,049C++ g++ #8 33.3912.3232,388742  36% 36% 100% 100%
4,057Pascal Free Pascal 80.5930.3432,456820  91% 40% 95% 41%
4,092Fortran Intel #5 56.7856.8032,732508  0% 0% 100% 0%
4,186Go #2 41.7510.4833,484837  100% 100% 100% 100%
4,640Haskell GHC #2 45.8111.4937,116782  100% 100% 100% 100%
5,091Python 3 #5 33 min8 min40,728449  100% 100% 100% 100%
5,150Perl 55 min13 min41,196579  100% 100% 100% 100%
5,936Lisp SBCL #3 46.6018.2047,484888  32% 40% 92% 93%
6,804Scala 48.1912.2254,428724  98% 98% 99% 100%
7,047C# Mono #3 44.9611.4256,376701  98% 98% 98% 100%
7,128C# Mono #6 31.548.0657,024986  98% 97% 99% 98%
7,165C# Mono #4 31.628.0957,316872  97% 98% 99% 97%
7,187Fortran Intel #4 48.4318.4157,492611  96% 34% 95% 41%
7,205F# Mono #3 44.7311.3857,640800  98% 98% 99% 98%
7,309C# Mono 46.0211.6958,472798  98% 98% 99% 99%
7,542Lisp SBCL 28.567.8460,3322459  95% 87% 99% 85%
7,555Racket #4 71.6118.1160,436796  99% 99% 100% 99%
7,793Java  #2 27.847.1162,344796  98% 97% 98% 100%
7,802Java  #3 50.8812.8862,416903  99% 99% 100% 98%
7,804Java  #6 28.087.1762,432802  98% 97% 98% 99%
8,095F# Mono #4 33.998.8364,760869  96% 96% 96% 97%
9,629Ruby #4 34 min34 min77,032866  25% 26% 25% 26%
10,379Scala #5 43.6515.9183,032589  98% 40% 72% 65%
10,787Hack 1h 11 min1h 11 min86,296441  0% 100% 0% 0%
13,422Hack #2 283.58283.69107,372458  1% 0% 100% 1%
14,476PHP #3 21 min5 min115,808863  100% 100% 100% 100%
14,931Clojure #5 52.4150.68119,4441069  4% 83% 7% 21%
15,675Clojure #6 54.5415.28125,4001069  91% 89% 88% 89%
18,053Clojure #7 32.128.94144,4241195  88% 96% 86% 91%
22,492Ruby #2 36 min9 min179,936925  100% 100% 100% 100%
26,973Dart 57.0621.01215,784901  99% 90% 38% 46%
35,698Scala #4 28.567.42285,580786  96% 96% 98% 96%
78,722Ruby JRuby #3 18 min18 min629,772307  24% 31% 29% 19%
89,085Ruby JRuby #2 2h 05 min31 min712,676925  99% 99% 99% 99%
156,622Erlang 32 min8 min1,252,976534  98% 98% 98% 98%
158,689Erlang HiPE 274.0377.841,269,512534  88% 96% 85% 84%
282,839Ruby JRuby #4 56 min14 min2,262,712866  98% 98% 98% 98%
Fortran Intel #2 Bad Output813
Fortran Intel #3 Bad Output754
Fortran Intel Bad Output485
Hack #3 Failed864
Pascal Free Pascal #2 Make Error817
Python 3 #3 Failed304
Rust Bad Output1386
Scala #3 Failed796
"wrong" (different) algorithm / less comparable programs
2,010C gcc #5 7.321.8516,0801026
3,411C++ g++ 10.742.7027,2881239
3,991C gcc #8 16.014.0231,924859
6,516Python 3 #6 120.6630.9952,1241380

 mandelbrot benchmark : Generate Mandelbrot set portable bitmap file

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