tech-toolchain archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: gcc build is serialised



On Thu, 01 May 2008, David Holland wrote:
>  > The manual page for make says this:
>  > 
>  >      The way that parallel makes are scheduled changed in NetBSD 4.0 so
>  >      that .ORDER and .WAIT apply recursively to the dependant nodes.  The
>  >      algo- rithms used may change again in the future.
>
> This is maybe a stupid question, but how can .WAIT be recursive? It
> establishes a barrier, which, by its nature, can only be in one
> specific place. (Or at least that's how I thought it worked.)

What's meant by "recursive" in this context is that,
given a Makefile with rules like this:

        all: a .WAIT b
        a: x ; echo making a
        b: y ; echo making b
        x: ; echo making x
        y: ; echo making y

then, not only will "a" be made before "b", but also "x" will be made
before "y".  More generally, anything that gets made as a result of
making "a" will be made before the barrier, and everything that gets
made as a result of making "b" will be made after the barrier.  (If both
"a" and "b" depend (directly or indirectly) on the same thing, then that
thing will be made only once, before the barrier.)

--apb (Alan Barrett)


Home | Main Index | Thread Index | Old Index