mandelbrot benchmark N=16,000

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

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.

    sortsortsort 
  ×   Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
1.0Ruby #3 31 min31 min7,508307  1% 1% 0% 100%
1.0Ruby JRuby #3 17 min17 min654,688307  0% 1% 1% 100%
1.1Lua 11 min11 min1,320353  0% 0% 0% 100%
1.2Lua #2 13 min13 min1,024367  0% 0% 0% 100%
1.3C gcc #2 47.2347.25396400  1% 0% 1% 100%
1.3C++ g++ #3 74.5774.601,068414  1% 1% 0% 100%
1.4Hack 1h 11 min1h 11 min86,264441  1% 0% 0% 100%
1.4PHP 20 min20 min4,248443  0% 1% 1% 100%
1.4OCaml #6 56.3856.403,132444  0% 0% 0% 100%
1.5Python 3 #5 33 min33 min40,324449  1% 1% 1% 100%
1.5Scala #2 51.6851.7024,260454  1% 0% 1% 100%
1.5Hack #2 283.88283.99105,380458  1% 1% 0% 100%
1.5Smalltalk VisualWorks #2 9 min9 min42,596467  0% 0% 0% 100%
1.6C# Mono #2 132.62132.6821,752484  1% 0% 0% 100%
1.7Fortran Intel #5 54.7854.7932,460508  0% 0% 0% 100%
1.7Racket 102.97103.0017,824517  0% 0% 1% 100%
1.7Pascal Free Pascal #3 75.4375.478530  1% 0% 1% 100%
1.7Erlang HiPE 242.37242.621,221,972534  0% 0% 0% 100%
1.9Ada 2005 GNAT #2 57.1857.201,232572  1% 0% 0% 100%
1.9Racket #2 88.1588.4420,240585  1% 1% 1% 100%
1.9Scala #5 43.2943.3185,100589  1% 0% 0% 100%
1.9C++ g++ #5 37.6337.6432,260590  1% 0% 1% 100%
2.0Fortran Intel #4 47.4047.4154,164611  0% 0% 0% 100%
2.0Lua #6 14 min14 min24,928623  0% 0% 0% 100%
2.2Java  42.7242.7419,564665  1% 0% 0% 100%
2.2C++ g++ #2 39.5539.5632,328687  0% 0% 1% 100%
2.3C gcc #9 19.3819.3931,460694  0% 0% 1% 100%
2.3Go #6 47.0747.0933,472700  1% 0% 1% 100%
2.3C# Mono #3 44.9244.9456,572701  1% 1% 0% 100%
2.3OCaml 55.7755.926,548710  0% 0% 0% 100%
2.4Scala 47.4347.4554,860724  1% 2% 2% 100%
2.4C++ g++ #9 33.0633.0732,388726  1% 1% 0% 100%
2.4C++ g++ #8 33.3633.3832,388742  1% 0% 0% 100%
2.4Pascal Free Pascal #4 68.1568.1830,380748  1% 0% 0% 100%
2.5C gcc #3 24.0824.0931,644763  0% 1% 0% 100%
2.5Python 3 #2 27 min27 min110,552777  0% 1% 1% 100%
2.5Haskell GHC #2 45.5345.5538,532782  1% 0% 0% 100%
2.6Scala #4 28.4328.44239,568786  0% 1% 1% 100%
2.6Racket #4 71.5971.6161,184796  0% 0% 0% 100%
2.6Java  #2 23.8123.8272,688796  0% 1% 0% 100%
2.6Racket #3 74.4074.4221,036797  1% 1% 1% 100%
2.6C# Mono 45.9245.9460,336798  1% 1% 0% 100%
2.6C gcc #4 24.1524.1631,660799  0% 1% 1% 100%
2.6F# Mono #3 44.4644.4759,784800  1% 1% 0% 100%
2.6Java  #6 27.5227.5473,004802  1% 1% 1% 100%
2.7Pascal Free Pascal 80.5880.6133,612820  1% 0% 0% 100%
2.7C gcc 24.6224.6331,116822  1% 1% 1% 100%
2.7Pascal Free Pascal #5 134.95135.0131,372829  1% 1% 1% 100%
2.7Go #2 43.2043.2233,460837  1% 1% 0% 100%
2.8PHP #3 20 min20 min116,072863  0% 1% 1% 100%
2.8Ruby JRuby #4 20 min20 min2,288,224866  1% 1% 1% 100%
2.8Ruby #4 35 min35 min81,028866  1% 1% 1% 100%
2.8F# Mono #4 34.9935.0065,100869  1% 1% 0% 100%
2.8C# Mono #4 31.6731.6961,216872  1% 1% 0% 100%
2.9C gcc #6 24.6224.6431,116879  1% 1% 1% 100%
2.9Lisp SBCL #3 46.5946.6147,484888  0% 0% 1% 100%
2.9Dart 57.2357.26222,500901  1% 1% 0% 100%
2.9Java  #3 42.4942.5172,692903  1% 1% 1% 100%
3.0Ruby #2 37 min37 min175,476925  1% 1% 1% 100%
3.0Ruby JRuby #2 22 min22 min708,540925  1% 1% 1% 100%
3.2C# Mono #6 31.5331.5457,428986  1% 1% 0% 100%
3.2C gcc #7 24.2224.2331,868994  1% 1% 0% 100%
3.3C++ g++ #7 23.7523.7632,3881017  1% 1% 0% 100%
3.4C++ g++ #6 28.6428.6531,6721035  0% 1% 1% 100%
3.4F# Mono #2 184.44184.5124,5201043  1% 1% 0% 100%
3.5Clojure #5 52.0452.06117,5921069  0% 0% 0% 100%
3.5Clojure #6 53.7653.79122,6321069  0% 0% 1% 100%
3.9Clojure #7 32.6932.71139,5881195  1% 1% 0% 100%
5.9Ada 2005 GNAT #3 22.7422.7730,3441805  1% 0% 0% 100%
8.0Lisp SBCL 28.5628.5760,3362459  0% 1% 0% 100%
Fortran Intel #2 Bad Output813
Fortran Intel #3 Bad Output754
Fortran Intel Bad Output485
Hack #3 Failed864
JavaScript V8 #2 Bad Output353
Pascal Free Pascal #2 Make Error817
Perl Failed579
Python 3 #3 Failed304
Rust Bad Output1386
Scala #3 Failed796
"wrong" (different) algorithm / less comparable programs
2.8C gcc #8 15.1915.2031,924859
3.3C gcc #5 7.307.3116,0801026
4.0C++ g++ 10.6010.6131,6281239
4.5Python 3 #6 120.00120.1552,1281380

 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