automake
[Top][All Lists]
Advanced

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

Re: Compilation order


From: Paul Smith
Subject: Re: Compilation order
Date: Mon, 29 Sep 2008 15:48:43 -0400

On Mon, 2008-09-29 at 21:41 +0200, Ralf Wildenhues wrote:
> When run in parallel (-jN) mode, make doesn't guarantee any order of
> rule execution except that implied by the dependency relations.

To be really, really pedantic: even in parallel mode, make (currently)
always relies on the order in which prerequisites are listed for a given
target.  However, since make is running them in parallel you can't
really tell which items might end up running together: it depends on how
the OS schedules the jobs and how long they take to complete, as well as
how large your N for -jN is.

There is an enhancement request for GNU make that hopes for a
randomization (to help find missing dependency relationships) of the
prerequisites.  However this is a large, difficult problem the way GNU
make is coded.

However your conclusion is absolutely correct: "you shouldn't rely on [a
specific order of prerequisite builds]".






reply via email to

[Prev in Thread] Current Thread [Next in Thread]