First build-infra push to jdk8 -- try out the new build system!
Magnus Ihse Bursie
magnus.ihse.bursie at oracle.com
Mon May 14 09:49:50 UTC 2012
On 2012-04-13 16:46, Jonathan Gibbons wrote:
> On 04/13/2012 02:07 AM, Magnus Ihse Bursie wrote:
>> As for the --with-num-cores, yes, it is a configure time option. The
>> underlying assumption is that your hardware doesn't really change,
>> and if your build system is too weak, it will be too weak at
>> configure time and at all make times. With that said, it is always
>> possible (and not very hard) to re-run configure if you need to tweak
>> such a parameter.
> As a developer, my machoine may not change, but my expectations may.
> Sometimes I want a build to run in the background while I pursue other
> activities, whether tetris, browsing, or working on the next bug
> fix. Other times, I need the build ASAP. So while your underlying
> assumption is good for batch build systems, it may not always be true
> on developer machines.
We have now implemented the possibitlity to override the default
parallelism using the standard make -j option. In short, if you just
type "make" you will be using the number of cores detected by (or
explicitely configured in) configure, which will make the default build
be as fast as possible.
If you want to make a slower build but save some CPU power for other
processes, you can run e.g. "make -j 2". This will force the makefiles
to only run 2 parallel processes, or even "make -j 1" which will disable
If you want to have it the other way round, namely having slow builds
default and override with fast if you're impatient, you should call
configure with --with-num-cores=2, making 2 the default. If you want to
run with more cores, run "make -j 8" or just "make -j"; the latter will
let make determine the maximum number of parallel jobs.
This features is currently implemented in the build-infra forest, but it
is scheduled for merging into the build forest at the next push. (Webrev
coming up soon...)
More information about the build-dev