From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id IAA20836; Mon, 22 Mar 2004 08:49:12 +0100 (MET) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id IAA19903 for ; Mon, 22 Mar 2004 08:49:10 +0100 (MET) X-SPAM-Warning: Sending machine is listed in blackholes.five-ten-sg.com Received: from oxy.exomi.com (ua183d70hel.dial.kolumbus.fi [62.248.249.183]) by concorde.inria.fr (8.12.10/8.12.10) with ESMTP id i2M7n9Hd024062 for ; Mon, 22 Mar 2004 08:49:09 +0100 Received: from [127.0.0.1] (localhost [127.0.0.1]) by oxy.exomi.com (Postfix) with ESMTP id 5055F1832E9; Mon, 22 Mar 2004 09:49:55 +0200 (EET) In-Reply-To: <405DD298.109@columbia.edu> References: <20040321062143.BE7D29BBA2@orchestra.cs.caltech.edu> <405D4D77.2030403@columbia.edu> <20040321084008.429279BBA2@orchestra.cs.caltech.edu> <405DBE78.5020609@columbia.edu> <1079888775.3165.11.camel@pelican.wigram> <405DD298.109@columbia.edu> Mime-Version: 1.0 (Apple Message framework v613) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: <819CA932-7BD5-11D8-9C9B-000393863F70@exomi.com> Content-Transfer-Encoding: 7bit Cc: Michael Vanier , skaller@users.sourceforge.net, caml-list From: Ville-Pertti Keinonen Subject: Re: [Caml-list] extensible records again Date: Mon, 22 Mar 2004 09:49:54 +0200 To: Oleg Trott X-Mailer: Apple Mail (2.613) X-Miltered: at concorde by Joe's j-chkmail ("http://j-chkmail.ensmp.fr")! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 extensible:01 oleg:01 arrays:01 compiler:01 compilers:01 compilers:01 semantics:01 ocaml:01 ocaml:01 lisp:01 trivial:01 native-code:02 native-code:02 compile:02 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk X-Status: X-Keywords: X-UID: 299 On Mar 21, 2004, at 7:36 PM, Oleg Trott wrote: > If I were writing a dynamically-typed language implementation in > O'Caml, I'd _compile_ it _to_ O'Caml (as opposed to interpreting the > language) In fact, except for EVAL and CALL/CC, it's probably very > trivial to write a Scheme-to-OCaml compiler, and get the performance > on par with decent native-code Scheme compilers. How would you handle interactive sessions? Anyway, I'm pretty sure call/cc is far easier than getting good performance, all you need to do is use CPS, which is simple and efficient in OCaml. If you want the code to run fast, you need to do something to make function calls more direct (no lists or arrays of arguments)... The native-code Scheme compilers I've tried aren't too impressive, they can produce fast code but not safely and/or not with the full language semantics, one of the things restricting them is using C as an intermediate language (OCaml as an intermediate language would suffer from most of the same problems). Decent Common Lisp systems work far better, producing native code directly, even in interactive sessions. ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners