ANN: erlxec (was: Re: small poll)
Fri Dec 12 04:47:56 CET 2003
On Thu, 11 Dec 2003 10:20:39 +0100
"WILLIAMS Dominic" <D.WILLIAMS@REDACTED> wrote:
> Please don't make compile times any longer!
If it's the slowness of "erlc" that's got you down, you might want to
check out "erlxec":
(Those who are Tragically Firewalled may have better luck trying
erlxec is basically a rewrite, in C, of a Perl script I was working on a
couple of months ago called 'tellerl'. erlxec is like erl_call, except
optimized for running Erlang functions as if they were utility programs,
from the operating system shell. The logic goes kind of like this:
- The startup and shutdown times of the BEAM emulator are dismal.
- But that's forgivable, because it's primarily for long-running tasks,
not short-lived utilities.
- But "erlc" is a short-lived utility and it starts a BEAM emulator.
- But you can get around that by using c(module) in EShell.
- But you can't do that inside a Makefile without, uhm, starting a BEAM
- But you can start a BEAM emulator in the background first, then use
- But erl_call doesn't understand when you change the current working
directory and/or environment variables, and other little things.
- So write a little program like erl_call except different.
It's still at the proof-of-concept stage, but the proof is in the
pudding (or test run, as the case may have it) (drum roll, please):
- A rebuild of the entire Jungerl, with "ERLC := /usr/local/bin/erlc",
took 10 minutes 24 seconds on my machine.
- With "ERLC := erlxec erlc" it took only 5 minutes 4 seconds.
The source code (erlxec.c) more than likely has some FreeBSDisms in it;
I'd greatly appreciate some help making it more portable, even if it's
only a report of how it fails to compile on Linux and other systems.
More information about the erlang-questions