From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by yquem.inria.fr (Postfix) with ESMTP id 9472FBB9A for ; Sat, 29 Oct 2005 01:07:43 +0200 (CEST) Received: from web26810.mail.ukl.yahoo.com (web26810.mail.ukl.yahoo.com [217.146.176.86]) by nez-perce.inria.fr (8.13.0/8.13.0) with SMTP id j9SN7h7v019398 for ; Sat, 29 Oct 2005 01:07:43 +0200 Received: (qmail 29011 invoked by uid 60001); 28 Oct 2005 23:07:43 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.de; h=Message-ID:Received:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=Lw3Rm4o/RNffHtx5UAWWdrGiZ9t9U0v0j7O92x0w5IEzkuup/5dwFyBAs4pTj/lehV3UAarPY36UpHJAxILisVAWi2psH7cmLdAe6uWh6LHXKw6s/vJvjxU6WesS/gxFnTSQJGTZIXtBbF0p6xVWFqcj2mpH4BumHdp28OD7kpk= ; Message-ID: <20051028230743.29009.qmail@web26810.mail.ukl.yahoo.com> Received: from [83.180.67.42] by web26810.mail.ukl.yahoo.com via HTTP; Sat, 29 Oct 2005 01:07:42 CEST Date: Sat, 29 Oct 2005 01:07:42 +0200 (CEST) From: Martin Chabr Subject: Ant: [Caml-list] Re: OCaml efficiency/optimization? To: Tato Thetza Cc: caml-list@yquem.inria.fr In-Reply-To: <1130495033.8413.246225066@webmail.messagingengine.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Miltered: at nez-perce with ID 4362AF3F.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; caml-list:01 ocaml:01 ocaml:01 avoided:01 caml-list:01 beginner's:01 beginners:01 bug:01 gesendet:98 jetzt:98 anmelden:98 immutable:01 bin:01 data:02 caml:02 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.4 required=5.0 tests=DNS_FROM_RFC_ABUSE autolearn=disabled version=3.0.3 The second reference you mentioned (Ocaml for Experienced Programmers by Brian Hurt) is an excellent and very detailed introduction to functional programming in OCaml for C/C++/Java etc. programmers. It explaines a lot on the subject of optimization which I have not found elsewhere: It makes clear how OCaml uses the built-in singly linked lists, the role of data sharing in these and what should be avoided for fast performance. I think that this book contains more "secrets to be used in production" than any other tutorial I know. Another tutorial you might have a look at is the one by Rich Jones of Merjis Co. at: http://www.ocaml-tutorial.org/ It contains a chapter on performance and profiling at: http://www.ocaml-tutorial.org/performance_and_profiling Martin --- Tato Thetza schrieb: > sorry I meant > Ocaml for Experienced Programmers: > http://www.bogonomicon.com/bblog/book/html/book1.html > > On Fri, 28 Oct 2005 03:21:43 -0700, "Tato Thetza" > > said: > > I've been reading over > > > http://caml.inria.fr/pub/docs/manual-ocaml/index.html > and have learned > > two things: > > -lists are immutable and singly linked, which > explains why 1::[2;3] is > > valid while [2,3]::1 is not, and why its > efficient. > > -the proper way to ensure tail-recursive > optimization > > > > question: are these and other optimizations > documented somewhere > > officially? I find it a little uncomfortable I've > been learning OCaml > > without knowning such internal details. Any > secrets I should definitely > > know if I were to use this language in production? > > > > thanks, > > Tato Thetza > > _______________________________________________ > Caml-list mailing list. Subscription management: > http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list > Archives: http://caml.inria.fr > Beginner's list: > http://groups.yahoo.com/group/ocaml_beginners > Bug reports: http://caml.inria.fr/bin/caml-bugs > ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de