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 GAA24038; Thu, 26 Aug 2004 06:17:47 +0200 (MET DST) 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 GAA30333 for ; Thu, 26 Aug 2004 06:17:46 +0200 (MET DST) Received: from outbound28-2.lax.untd.com (outbound28-2.lax.untd.com [64.136.28.160]) by concorde.inria.fr (8.13.0/8.13.0) with SMTP id i7Q4HiXO012629 for ; Thu, 26 Aug 2004 06:17:45 +0200 Received: from outbound28-2.lax.untd.com (smtp04.lax.untd.com [10.130.24.124]) by smtpout05.lax.untd.com with SMTP id AABAU43B8AA5UDTJ for (sender ); Wed, 25 Aug 2004 21:17:02 -0700 (PDT) Received: (qmail 22792 invoked from network); 26 Aug 2004 04:16:02 -0000 Received: from unknown (HELO vangogh) (66.52.204.90) by smtp04.lax.untd.com with SMTP; 26 Aug 2004 04:16:02 -0000 From: "Brandon J. Van Every" To: "caml" Subject: [Caml-list] bytecode and native code at once Date: Wed, 25 Aug 2004 21:26:54 -0700 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) In-Reply-To: <200408251909.03050.jgoerzen@complete.org> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 Importance: Normal X-ContentStamp: 11:5:1728685677 X-UNTD-OriginStamp: CI84cOLHFqh7Zd2QWkwvEFvwyO3T/pIsFsCrOjjLH87mXYscXjV1rrfWnw70/acK X-Miltered: at concorde with ID 412D6468.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; brandon:99 ocamlopt:01 caml-list:01 bayesian:01 crap:01 crap:01 unboxed:01 alloc:01 alloc:01 val:01 val:01 bigarray:01 bytecode:01 bytecode:01 int:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk John Goerzen wrote: > > An *efficient* implementation is another matter, but one I'm > not highly > concerned about. Those that are going to be doing sophisticated > numerical analysis can stick with ocamlopt. I do wish bytecode and native code could be combined in the same application. This is a typical game development scenario. One might wish to edit a Massively Multiplayer Online Game server 'live', for example. Some parts must be fast. Other parts aren't so performance critical and would be better seen as 'scripting jobs'. Game development encompasses both the need for heavy duty number crunching and the need to script. Cheers, www.indiegamedesign.com Brand*n Van Every S*attle, WA Praise Be to the caml-list Bayesian filter! It blesseth my postings, it is evil crap! evil crap! Bigarray! Unboxed overhead group! Wondering! chant chant chant... Is my technical content showing? // return an array of 100 packed tuples temps int $[tvar0][2*100]; // what the c function needs value $[tvar1]; // one int value $[tvar2]; // one tuple int $[tvar3] // loop control var oncePre eachPre $[cvar0]=&($[tvar0][0]); eachPost $[lvar0] = alloc(2*100, 0 /*NB: zero-tagged block*/ ); for(int $[tvar3]=0;$[tvar3]<100;$[tvar3]++) { $[tvar2] = alloc_tuple(2); $[tvar1] = Val_int($[cvar0][0+2*$[tvar3]]); Store_field($[tvar2],0,$[tvar1]); $[tvar1] = Val_int($[cvar0][1]); Store_field($[tvar2],1,$[tvar1+2*$[tvar3]]); Array_store($[lvar0],$[tvar3],$[tvar0]); } oncePost ------------------- 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