On Mon, Jan 17, 2011 at 20:36, Bakul Shah <[email protected]> wrote:
> On Mon, 17 Jan 2011 11:56:22 EST erik quanstrom <[email protected]>  
> wrote:
>> > strace tells you what system calls were made and when.  To
>> > find out which functions use most time, compile with -pg and
>> > look at the gprof output once done.  That 14 seconds were
>> > probably spent computing dependencies.  You can convert your
>> > test.mk to a Makefile with a trivial sed script. See what
>> > bsdmake or gmake does with it time wise. {bsd,g}make have
>> > been been abused with huge Makefiles for far longer and are
>> > likely to be friendlier to them :-)
>
>> i don't see how comparing with *make would get one closer
>> to solving the mystery.
>
> The comparison would reveal if other makes do better. I
> suspect they do and that would solve Ciprian's problem.

    Ok. So I've transformed (with a `sed` script as suggested) the
script from `mk` to GNU `make. The results is as follows:
    * building the entire thing with no parallelism took as in my
experiment -- when I've just obtained the raw commands and runned them
with plain sh -- about 1 minute and 27 seconds seconds;
    * after the build issuing `make` a second time take under one
second (0.2 seconds);

    I'll try now to profile the `mk` tool as suggested.

    Ciprian.

    P.S.: I'm not suggesting that GNU `make` is a better tool, just
that for this particular task it behaves better. (Actually I find it
overly complex and almost incomprehensible in its full
implications...)

Reply via email to