/mobile Handheld Friendly website
x64 Ubuntu : Intel® Q6600® one core |
Each chart bar shows, for one unidentified benchmark, how much the fastest OCaml program used compared to the fastest Haskell GHC program.
These are not the only compilers and interpreters. These are not the only programs that could be written. These are not the only tasks that could be solved. These are just 10 tiny examples.
Each table row shows, for one named benchmark, how much the fastest OCaml program used compared to the fastest Haskell GHC program.
| OCaml used what fraction? used how many times more? | ||||
|---|---|---|---|---|
| Benchmark | Time | Memory | Code | |
| regex-dna | ± | 2× | 1/2 | |
| pidigits | ± | 2× | 2× | |
| fannkuch-redux | ± | 6× | 2× | |
| k-nucleotide | ± | ± | ± | |
| spectral-norm | ± | ± | 1/3 | |
| n-body | ± | 1/3 | 1/2 | |
| reverse-complement | ± | 1/4 | ± | |
| mandelbrot | ± | 1/6 | ± | |
| binary-trees | 2× | 1/2 | ± | |
| fasta | 3× | 76× | ± | |
| OCaml used what fraction? used how many times more? | |||||||
|---|---|---|---|---|---|---|---|
| Time-used | |- | |--- | 25% | median | 75% | ---| | -| |
| (Elapsed secs) | ± | ± | ± | ± | ± | 2× | 3× |
± read the measurements and then read the program source code.
These are not the only tasks that could be solved. These are just 10 tiny examples. These are not the only compilers and interpreters. These are not the only programs that could be written.
For each named benchmark, measurements of the fastest OCaml program are shown for comparison against measurements of the fastest Haskell GHC program.
| Program Source Code | CPU secs | Elapsed secs | Memory KB | Code B | ≈ CPU Load |
|---|---|---|---|---|---|
| regex-dna | |||||
| OCaml | 18.87 | 18.90 | 555,452 | 615 | 0% 0% 0% 100% |
| Haskell GHC | 27.21 | 27.22 | 329,352 | 1518 | 0% 1% 0% 100% |
| pidigits | |||||
| OCaml | 2.80 | 2.81 | 8,776 | 560 | 2% 0% 1% 100% |
| Haskell GHC | 3.40 | 3.41 | 5,788 | 341 | 0% 1% 0% 100% |
| fannkuch-redux | |||||
| OCaml | 0.00 | 65.32 | 11,296 | 1004 | 0% 0% 0% 100% |
| Haskell GHC | 66.34 | 66.36 | 1,972 | 658 | 0% 0% 0% 100% |
| k-nucleotide | |||||
| OCaml | 57.82 | 57.89 | 258,480 | 1789 | 0% 0% 0% 100% |
| Haskell GHC | 58.22 | 58.29 | 357,524 | 1693 | 0% 0% 0% 100% |
| spectral-norm | |||||
| OCaml | 15.69 | 15.69 | 1,796 | 377 | 0% 0% 0% 100% |
| Haskell GHC | 15.69 | 15.70 | 1,460 | 984 | 0% 0% 0% 100% |
| n-body | |||||
| OCaml | 23.82 | 23.83 | 712 | 1239 | 1% 0% 0% 100% |
| Haskell GHC | 22.93 | 22.94 | 2,240 | 1874 | 0% 0% 0% 100% |
| reverse-complement | |||||
| OCaml | 0.00 | 1.59 | 31,272 | 1314 | 1% 0% 3% 100% |
| Haskell GHC | 1.25 | 1.26 | 126,096 | 999 | 1% 1% 0% 100% |
| mandelbrot | |||||
| OCaml | 55.40 | 55.56 | 6,308 | 710 | 0% 0% 0% 100% |
| Haskell GHC | 43.36 | 43.38 | 38,408 | 782 | 0% 0% 0% 100% |
| binary-trees | |||||
| OCaml | 40.93 | 40.99 | 223,176 | 496 | 0% 0% 0% 100% |
| Haskell GHC | 21.75 | 21.78 | 361,864 | 521 | 0% 0% 0% 100% |
| fasta | |||||
| OCaml | 10.51 | 10.52 | 198,332 | 1161 | 0% 0% 0% 100% |
| Haskell GHC | 3.56 | 3.56 | 2,624 | 979 | 0% 1% 0% 100% |
| fasta-redux | |||||
Remember - those are just the fastest OCaml and Haskell GHC programs measured on this OS/machine. Check if there are other implementations of these benchmark programs for OCaml.
Maybe one of those other OCaml programs is fastest on a different OS/machine.
Remember - those are just the fastest OCaml and Haskell GHC programs measured on this OS/machine. Check if there are faster implementations of these benchmark programs for other programming languages.
Maybe one of those other programs is fastest on a different OS/machine.
The OCaml native-code compiler, version 4.00.1
Home Page: http://www.ocaml.org/
Download: http://caml.inria.fr/download.en.html