From: Xavier Urbain <urbain@lri.fr>
Date: Thu, 7 Oct 1999 14:37:00 +0200 (MET DST)
To: caml-list@inria.fr
Subject: Re: speed versus C
In-Reply-To: <37FC4419.6C9E3B02@maxtal.com.au>
<99100522193302.17263@ice>
While talking about efficiency of ocaml versus C, I have to say that
as JC-Filliatre said before concerning gmp and num, we tried several
algorithms in order to compute huge fibonacci numbers. We are as
efficient (and in one case much more) as C with nice readable code as
a bonus. Actually most of the time is spent in gmp (far better than num
in THAT case) so... I should put those files on my web page.
Concerning other problems like "solitaire" solver or emacs' mpuz
solver (without any extenal library) we have quite comparable times.
I strongly agree with Gerd Stolpmann when he write that ocaml offer
the opportunity of coding directly (I should add "naturally") more
sophisticated algorithms.
Finally remember that the ocamlopt compiler makes NO OPTIMIZATION (not
even multiplication by constant).
Try then C code compiled without flags such as -O3
-fomit-frame-pointer and so on.
Xavier
--Xavier Urbain --------------------------------------------------------------- L.R.I., Bât 490 mailto: Xavier.Urbain@lri.fr Université de Paris-Sud phoneto: (33) 1 69 15 42 32 F-91405 Orsay cedex faxto: (33) 1 69 15 65 86
http://www.lri.fr/Francais/Recherche/demons/membres/urbain.html ---------------------------------------------------------------
This archive was generated by hypermail 2b29 : Sun Jan 02 2000 - 11:58:26 MET