Date: Thu, 14 Dec 2006 16:33:11 -0500 From: Garance A Drosehn <gad@FreeBSD.org> To: freebsd-hackers@FreeBSD.org Subject: Re: [PATCH] "automated" make -j value Message-ID: <p06240802c1a76c5a2ad1@[128.113.24.47]> In-Reply-To: <20061214185203.GA9701@pix.net> References: <20061214041952.GA7513@dragon.NUXI.org> <20061214185203.GA9701@pix.net>
next in thread | previous in thread | raw e-mail | index | archive | help
At 1:52 PM -0500 12/14/06, Kurt J. Lidl wrote: >On Wed, Dec 13, 2006, David O'Brien wrote: > > With multi-socket systems becoming more prevalent, and the continued >> increase in cores per processors, I thought it would be nice for >> 'make -j' to gain some automation. >> >> Attached is a patch that makes "-j-" be the same as > > "-j `sysctl -n kern.smp.cpus`" and "-j=" be twice that. > >I think you can do it better than this, by just support >setting the concurrancy level via reading a environmental >variable. Like say "NPROC", which is what CrayOS used, and >also appeared in the BSD/OS pmake varient several years ago. You could have '-j-' use the value of NPROC if that variable is set, and fall back to kern.smp.cpus if NPROC is not set. (it also seems to me this could be called "-j auto" instead of using some single-character for it). I think is not going to make much sense to have a special -j value for "twice ncpu" as we get machines with 12 or 16 CPU's. I doubt there would be many projects which could really take advantage of 32 streams even if there was no performance penalties. And for the few which do exist, the users could just set NPROC if they think that would do them any good. -- Garance Alistair Drosehn = drosehn@rpi.edu Senior Systems Programmer or gad@FreeBSD.org Rensselaer Polytechnic Institute; Troy, NY; USA
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?p06240802c1a76c5a2ad1>