[Libreoffice] How can I speed up a build?
michael.meeks at novell.com
Mon Oct 25 05:59:28 PDT 2010
On Sat, 2010-10-23 at 13:15 +1100, Mattias Johnsson wrote:
> it seems that everything is rebuilt which takes hours, even if only a
> few files have changed.
As Norbert says - this may be down to low-level header changes, which
have a big trickle-down effect on build-times (sorry).
> Second, although I'm using autogen.sh with the --with-num-cpus=5
> option, it appears that only one cpu is being utilized. Or possibly
> two at most - when I look at the output of "top" during the build, at
> most I only ever see one "cc1plus" process and one "dmake" process,
Oh - that is indeed odd. Of course, it really depends on which piece
you build here; some of the 'external' components eg. berkelydb may not
parallelise at all (though hopefully we get build-level parallelism,
building some other module in parallel - if indeed there is anything we
can do that for).
> and dmake is never using more that 1% of a cpu. Any thoughts?
Personally, I recommend using:
/autogen.sh --with-git --with-gcc-speedup=icecream --with-num-cpus=16 --with-max-jobs=4
Icecream stops the huge number of CPUs burning a hole in your CPU - by
throttling them internally, so the parallelism then is just exposed to
the icecream daemon. And you can boot up any old machines you have lying
around on your LAN to help out; I use several old laptops variously, and
build 7 wide or so [ I tend to tweak the icecream config on each build
slave to use <cpus>+1 to use the network latency nicely ].
If you are lucky (ie. work in the czech labs: I do not) - you can do
the central pre-processing on an 8 CPU beast, then dispatch the source
to a huge build farm, such that you get a ~20 minute build from
clean ;-) - for me it takes a couple of hours.
michael.meeks at novell.com <><, Pseudo Engineer, itinerant idiot
More information about the LibreOffice