Compare the performance of OCaml programs against some other language implementation.

For more information about the OCaml implementation we measured see ↓ about OCaml.

Compare to:

 OCaml comparison summary


1/2 1/3 1/4 … OCaml is better
Programs Time Memory Use Source Size Reduced N
chameneos-reduxNo program
fastaNo program
pidigitsFailed
regex-dna±41/3
nsieve±2±
fannkuch±±±
binary-trees±±±
nsieve-bits±21/3
partial-sums±1/2±
spectral-norm±±±
sum-file±±1/2
k-nucleotide241/2
reverse-complement241/2
mandelbrot2±1/2
recursive3±±
n-body4±±

± look at the measurements

 OCaml comparison measurements

Program & Logs CPU secs Memory KB Size B Elapsed secs ~ CPU Load
 regex-dna 
OCaml #25.5445,364615  
C++ GNU g++ #35.5812,7041588  
 nsieve 
OCaml #22.169,380295  
C++ GNU g++ #32.085,764313  
 fannkuch 
OCaml8.30592485  
C++ GNU g++ #27.78844554  
 binary-trees 
OCaml4.838,732469  
C++ GNU g++ #24.476,996541  
 nsieve-bits 
OCaml4.415,020176  
C++ GNU g++3.863,316494  
 partial-sums 
OCaml #24.64564508  
C++ GNU g++ #34.05852531  
 spectral-norm 
OCaml31.631,196369  
C++ GNU g++23.84900442  
 sum-file 
OCaml8.74692138  
C++ GNU g++ #26.47852260  
 k-nucleotide 
OCaml #213.8334,636845  
C++ GNU g++ #37.469,3041380  
 reverse-complement 
OCaml1.0247,244540  
C++ GNU g++ #30.5413,288810  
 mandelbrot 
OCaml #36.06716444  
C++ GNU g++ #43.028961097  
 recursive 
OCaml #27.471,120389  
C++ GNU g++ #22.401,008566  
 n-body 
OCaml54.006441239  
C++ GNU g++ #214.629321705  

 about OCaml

The Objective Caml toplevel, version 3.10.2

Home Page: http://www.ocaml.org/

Download: http://caml.inria.fr/download.en.html

Revised BSD license