Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 11 May 2007 23:40:05 +0200
From:      Benjamin Lutz <mail@maxlor.com>
To:        ports@freebsd.org
Subject:   Benchmark: -j{$NCPU} vs -j{$NCPU+1}
Message-ID:  <200705112340.09640.mail@maxlor.com>

next in thread | raw e-mail | index | archive | help
--nextPart19990703.rZQdD007cc
Content-Type: text/plain;
  charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Hello,

Now that I'm back from having to serve in the armed services, I've=20
picked up work on parallel building for the ports again. There is some=20
conventional wisdom floating around these parts that says you should=20
run make -j with a number one higher than the number of CPUs you have.=20
As I wondered what difference that makes, I ran some benchmarks. Since=20
maybe someone else is curious about this too, I'll publish my results=20
here.

Here's the summary: on my core 2 duo machine (=3D 2 CPUs), this is the=20
time improvement to build the port (just configuring and building, no=20
installation) with -j3 over -j2:

x11-toolkits/gtk20:  2%
x11/kdebase3:        1%
graphics/gimp-app:  24%
lang/gcc41:         12%

So basically, -j3 really is faster than -j2, although the difference is=20
substantial only for some ports.

Here's the script I use to produce the numbers, as well as my raw=20
results which contain much more detail:

http://www.maxlor.com/freebsd/files/parallel_benchmark.sh
http://www.maxlor.com/freebsd/files/parallel_benchmark.ods

Cheers
Benjamin

--nextPart19990703.rZQdD007cc
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQBGROK5zZEjpyKHuQwRAjlaAJ4lGWxnwHSOkGEfKd+Ba14yfWamLACeK+Nx
jMHFByCWHjOsTxXnQqIpsn8=
=di5W
-----END PGP SIGNATURE-----

--nextPart19990703.rZQdD007cc--



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