From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id LAA22168 for caml-red; Tue, 28 Nov 2000 11:40:50 +0100 (MET) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id CAA01466 for ; Tue, 28 Nov 2000 02:30:00 +0100 (MET) Received: from localhost.localdomain (ppp89.dyn147.pacific.net.au [210.23.147.89]) by nez-perce.inria.fr (8.11.1/8.10.0) with ESMTP id eAS1Tuv27755 for ; Tue, 28 Nov 2000 02:29:57 +0100 (MET) Received: from ozemail.com.au (IDENT:root@localhost [127.0.0.1]) by localhost.localdomain (8.9.3/8.8.7) with ESMTP id MAA21974; Tue, 28 Nov 2000 12:27:48 +1100 Message-ID: <3A230A14.4F9D99DB@ozemail.com.au> Date: Tue, 28 Nov 2000 12:27:48 +1100 From: John Max Skaller X-Mailer: Mozilla 4.7 [en] (X11; I; Linux 2.2.12-20 i686) X-Accept-Language: en MIME-Version: 1.0 To: Vitaly Lugovsky CC: caml-list@inria.fr Subject: Re: Dynamic loading. Again. References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: weis@pauillac.inria.fr Vitaly Lugovsky wrote: > > I think there is a reason to implement dynamic loading of native compiled > code for Ocaml (e.g. PIC code generation for some platforms), > as well as dynamycally linked runtime code (I just managed to link > bytecode runtime dynamically, so, it's not so impossible). It's just a > way to kill Java. My problem was different: in writing my Python interpreter, I needed to provide emulations for a set of dynamically loadable Python extensions. I had to link them all in statically, even though every 'module' has the same signature: when I added modules, I had to update a string -> function table. No way I would want clients adding extensions to have to mess with the source of the interpreter. Funny thing is, I can actually dynamically load and execute _Python_ extensions under my Ocaml written interpreter! They're written in C, and it's not so hard to write an Ocaml/C interface that can do dynamic loading. -- John (Max) Skaller, mailto:skaller@maxtal.com.au 10/1 Toxteth Rd Glebe NSW 2037 Australia voice: 61-2-9660-0850 checkout Vyper http://Vyper.sourceforge.net download Interscript http://Interscript.sourceforge.net