Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 13 Feb 2008 23:26:40 -0800
From:      Julian Elischer <julian@elischer.org>
To:        Bill Moran <wmoran@potentialtech.com>
Cc:        Ian FREISLICH <ianf@clue.co.za>, Ed Schouten <ed@fxq.nl>, current@freebsd.org
Subject:   Re: Testing box available.
Message-ID:  <47B3ED30.2040404@elischer.org>
In-Reply-To: <20080213090842.65b240e6.wmoran@potentialtech.com>
References:  <E1JPBzl-0000jo-Pp@clue.co.za>	<20080213073155.GA1340@hoeg.nl> <20080213090842.65b240e6.wmoran@potentialtech.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Bill Moran wrote:
> In response to Ed Schouten <ed@fxq.nl>:
> 
>> * Ian FREISLICH <ianf@clue.co.za> wrote:
>>> As an aside, a 64 way parallel make buildworld doesn't saturate the CPU.
>> I'm not sure, but I think if you do this:
>>
>> 	make -j64 <foo>
>>
>> it only spawns 64 processes to handle the top level make process. This
>> would mean we've got a couple of processes doing this:
>>
>> 	make -C bin
>> 	make -C lib
>> 	make -C sbin
>> 	make -C usr.bin
>> 	make -C usr.sbin
>>
>> and the other processes will just quit, because they don't have anything
>> to do. Right? :-)
> 
> Basically, -j tells make the _maximum_ number of jobs to run in parallel.
> I frequently do -j99, but I've never seen more than about 20.  You can't
> just look at it for a second, either.  Certain parts of the build
> process have more parallelism available than others, so you might look
> at it at a point where there are only a few.
> 
> If you really want to saturate it, copy the src tree a few times and
> start a make -j99 buildworld in all of them simultaneously :D
> 


my memory is that ohk changed make to have a fifo with N (as in -j N)
tokens in it and all child makes inherrit this fifo
(or get it's name from an environment variable or something)
and can only spawn extra makes if they can get a token.
When they have finished their work they pu the token back into the
fifo..

My memories of this may be somewhat inaccurate however.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?47B3ED30.2040404>