From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 7B275BB81 for ; Thu, 1 Dec 2005 18:03:40 +0100 (CET) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id jB1H3dqB004001 for ; Thu, 1 Dec 2005 18:03:39 +0100 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 SAA06924 for ; Thu, 1 Dec 2005 18:03:38 +0100 (MET) Received: from net.univ-savoie.fr (net.univ-savoie.fr [193.48.120.75]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id jB1H3cJW013122 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO) for ; Thu, 1 Dec 2005 18:03:38 +0100 Received: from post.bourget.univ-savoie.fr (post.bourget.univ-savoie.fr [193.48.120.73]) by net.univ-savoie.fr (8.12.3/jtpda-5.4) with ESMTP id jB1H3Xa8002327 ; Thu, 1 Dec 2005 18:03:33 +0100 Received: from [193.48.123.45] (d45.lama.univ-savoie.fr [193.48.123.45]) by post.bourget.univ-savoie.fr (8.12.3/jtpda-5.4) with ESMTP id jB1H3RJd007602 ; Thu, 1 Dec 2005 18:03:28 +0100 Message-ID: <438F2CE5.9030105@univ-savoie.fr> Date: Thu, 01 Dec 2005 18:03:33 +0100 From: Christophe Raffalli User-Agent: Mozilla Thunderbird 1.0.6-7.1.20060mdk (X11/20050322) X-Accept-Language: fr, en MIME-Version: 1.0 To: Jacques Garrigue Cc: daniel.buenzli@epfl.ch, caml-list@inria.fr Subject: Re: [Caml-list] How to compile different implementations of the same lib References: <20051130.211930.102965761.garrigue@math.nagoya-u.ac.jp> <4F70401E-AE91-4E5E-AF67-70FBDCC7C353@epfl.ch> <20051201.100719.07647797.garrigue@math.nagoya-u.ac.jp> In-Reply-To: <20051201.100719.07647797.garrigue@math.nagoya-u.ac.jp> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.33 (www . roaringpenguin . com / mimedefang) X-Miltered: at concorde with ID 438F2CEB.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 438F2CEA.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; christophe:01 raffalli:01 christophe:01 raffalli:01 univ-savoie:01 caml-list:01 lib:01 inlining:01 cmx:01 functor:01 dependancy:01 cmx:01 cmi:01 makefile:01 nativecode:01 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.3 > A result is that there cannot be any inlining between client and > library. Actually, this is even worse than that: this also prevents > direct function calls, as the concrete information about functions is > also in the .cmx. All calls will have to go through closures. Just > like when you call a function received as parameter, or inside a > functor. > I you actually decide that the dependancy is for .cmx instead of .cmi in the makefile (which is mandatory for nativecode) with proper -I option, it should also work (maybe with a make clean when you switch implementation) ? May be I still do not get the problem Anyway, there should be better support for implementation choice at link time, because this is a nice feature of ML ... > This suggests the other evident alternative: write the client as a > functor. This will not be slower! But this can be more painful if > there are several modules in the client... > > Jacques Garrigue > > _______________________________________________ > 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 > -- Christophe Raffalli Université de Savoie Batiment Le Chablais, bureau 21 73376 Le Bourget-du-Lac Cedex tél: (33) 4 79 75 81 03 fax: (33) 4 79 75 87 42 mail: Christophe.Raffalli@univ-savoie.fr www: http://www.lama.univ-savoie.fr/~RAFFALLI --------------------------------------------- IMPORTANT: this mail is signed using PGP/MIME At least Enigmail/Mozilla, mutt or evolution can check this signature. The public key is stored on www.keyserver.net ---------------------------------------------