Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 16 Sep 2001 00:33:59 +0200
From:      Erik Trulsson <ertr1013@student.uu.se>
To:        stable@FreeBSD.ORG
Subject:   Re: make -j4 vs -j8... 4 works, but 8 does not
Message-ID:  <20010916003359.A48953@student.uu.se>
In-Reply-To: <p05101001b7c97cb4f801@[128.113.24.47]>
References:  <5.1.0.14.0.20010915123606.035fcc18@192.168.0.12> <p05101001b7c97cb4f801@[128.113.24.47]>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Sep 15, 2001 at 06:06:10PM -0400, Garance A Drosihn wrote:

> [aside on those multiple builds that I did:  It was interesting that
> even though it was on a dual-processor system, there was not much of
> a speed improvement (on 4.3-stable) when going from -j4 to -j10.  Big
> improvement going from -j1 to -j4, but after that it didn't help much]

That sounds exactly like what I would expect. More than 2 (or maybe 3)
jobs per CPU is normally not going to make things go faster but might
actually slow it down.

Increasing the number of jobs running in parallell up to the number of
CPUs will naturally increase performance. (Since otherwise you have
some unused processors.)

The reason why running more than one job/CPU might be good is that the
processes uses a mixture of I/O and CPU. If you run two jobs in
parallell then one can use the CPU while the other waits for I/O. This
increases the efficiency in total resource usage.

If you run more than that things will not improve much since you can
only have one process using a CPU at a particular time. And if you have
several processes trying to access a disk at the same time the disk
will spend a lot of time seeking back and forth which is a sure way of
making a system slow.

So for a system with P processors the speed improvements for using -jN
with N > 2*P is normally going to be fairly small.  (While the speed
improvments when increasing N from 1 up to 2*P can often be noticable,
especially when going from 1 to P.)

-- 
<Insert your favourite quote here.>
Erik Trulsson
ertr1013@student.uu.se


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




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