Re: both native & bytecode
On Wednesday 27 October 2004 22:13, Berke Durak wrote:
> Hello all,
> On Wed, Oct 27, 2004 at 09:06:33PM +0200, Sven Luther wrote:
> > On Wed, Oct 27, 2004 at 07:21:45PM +0200, Samuel Mimram wrote:
> > > Hello,
> > >
> > > I have a few comments on your control file, I might be wrong since I
> > > don't really know ara :
> > > * if you don't need the Graphics or Tk modules, you should depend on
> > > the -nox versions of the packages (in particular for ara which does not
> > > require X, I guess). Anyway you don't need to depend on ocaml,
> > > ocaml-base and ocaml-base-nox since ocaml-base-nox is implied by
> > > ocaml-base which is implied by ocaml. So I would simply put
> > > ocaml-nox-3.08 in the Build-Depends.
> > > * Does xara-gtk really use lablgl? (it's in the build-deps)
> > It is transitivily depended by lablgtk2 anyway.
> > > * You should not build-depend on ocaml-native-compilers since it is not
> > > available on some non-native archs. You could depend on
> > > ocaml-best-compilers but anyway your app is, I guess, small enough not
> > > to require native compilers when available.
> > I thought so at first, but had second thought about it. Ara does pretty
> > heavy status file parsing, and it seem to know over 20k packages on my
> > install (sid + some stuff), so altough this is disk bound, a native code
> > version is well waranted (unless i am missing something).
> I second this. On my machine, the bytecode is 3 times slower than the
> native code, and it makes a usability difference : 2s vs 6s startup
> time on my P4 at 2.4GHz ; ara parses 39658 packages... On a Pentium
> 120 this would give approx. 20s vs a full minute and many people still
> have these, and ara will be important for these people since they usually
> can't use GTK2 stuff like Xara or Synaptic because it's too heavy.
> Another advantage of native code is that it doesn't depend on Ocaml
> PS. Thomas, Sven, George : are you all subscribed to debian-ocaml-maint ?
I've commited my changes to SVN, basically we first check if we can make a
native build, else fallback to bytecode...
if [ -x /usr/bin/ocamlopt ]; then \
$(MAKE) bt ; \
..... then we rename everythig to ara, xara
if [ -f $(CURDIR)/ara.opt ]; then cp $(CURDIR)/ara.opt $(CURDIR)/ara ; fi
if [ -f $(CURDIR)/xara.opt ]; then cp $(CURDIR)/xara.opt $(CURDIR)/xara ; fi
My feeling is that it is clean and short solution, comments ?
I'm presenly not subscribed to debian-ocaml-mailt, but if I do I'll let you
pub 4096R/0E4BD0AB 2003-03-18 <keyserver.bu.edu ; pgp.mit.edu>
fingerprint 1AE7 7C66 0A26 5BFF DF22 5D55 1C57 0C89 0E4B D0AB