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 KAA29551; Tue, 21 Sep 2004 10:23:15 +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 KAA03137 for ; Tue, 21 Sep 2004 10:23:14 +0200 (MET DST) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.189]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id i8L8NEBB019709 for ; Tue, 21 Sep 2004 10:23:14 +0200 Received: from [212.227.126.160] (helo=mrelayng.kundenserver.de) by moutng.kundenserver.de with esmtp (Exim 3.35 #1) id 1C9fvd-0002Q8-00; Tue, 21 Sep 2004 10:23:13 +0200 Received: from [80.129.113.238] (helo=gate.gerd-stolpmann.de) by mrelayng.kundenserver.de with asmtp (Exim 3.35 #1) id 1C9fvd-0002R9-00; Tue, 21 Sep 2004 10:23:13 +0200 Received: from ice.gerd-stolpmann.de (ice.gerd-stolpmann.de [192.168.0.13]) by gate.gerd-stolpmann.de (Postfix) with ESMTP id DBE555886; Tue, 21 Sep 2004 10:23:12 +0200 (CEST) Received: by ice.gerd-stolpmann.de (Postfix, from userid 1000) id 13028B033; Tue, 21 Sep 2004 10:23:11 +0200 (CEST) Subject: Re: [Caml-list] huuuuuge executable with pxp From: Gerd Stolpmann To: argentoff@rtelekom.ru Cc: ocaml In-Reply-To: <200409211203.49504.argentoff@rtelekom.ru> References: <200409211203.49504.argentoff@rtelekom.ru> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-Id: <1095754991.1134.8.camel@ice.gerd-stolpmann.de> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.5 Date: Tue, 21 Sep 2004 10:23:11 +0200 X-Provags-ID: kundenserver.de abuse@kundenserver.de auth:a6865a839c0178d9aa0ce41878507ea2 X-Miltered: at concorde with ID 414FE4F2.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 pxp:01 gerd:01 stolpmann:01 2004:99 pxp:01 ocamlfind:01 ocamlopt:01 wlex:01 wlex:01 slower:01 pxp-engine:01 gerd:01 stolpmann:01 viktoriastr:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Die, 2004-09-21 at 10:03, Paul Argentoff wrote: > Deal All, > > I really like pxp, but one thing makes me unhappy: when I compile my program > with "ocamlfind ocamlopt -package pxp my.ml", the resulting executable is ~3M > big. Is there any way of reducing this size? All I need is > parse/transform/write an UTF-8 XML text. What lexers are needed, what are > not? I guess you did not install wlex or ulex. The biggest part of the executable are the UTF-8 lexing tables of the ocamllex-based lexer (about 1M). By switching to the wlex or ulex lexer (the latter is only present in the newest release, but simpler to build), you can reduce the size of the executable significantly. These alternative lexers are a bit slower, however. After building them, compile your program with -package pxp-engine,pxp-ulex-utf8 or pxp-wlex-utf8. In general you need only the lexer that corresponds to the internal representation of the XML data. Gerd -- ------------------------------------------------------------ Gerd Stolpmann * Viktoriastr. 45 * 64293 Darmstadt * Germany gerd@gerd-stolpmann.de http://www.gerd-stolpmann.de ------------------------------------------------------------ ------------------- 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