Hi,

> >  My question is: how to build gcc bootstrap with  distcc correctly.
>
> I believe it is impossible in the general case. bootstrap means to
> compile GCC source code with a GCC compiler just built from the same
> source code. Hence, to distribute this compilation with distcc, you'll
> need to send the (stage1 compiled) GCC binaries on the network, and
> distcc is not able to send binary programs. (If you'll extend distcc
> to send binary programs - a non trivial task -, you open a new can of
> worms, and you'll need to tackle potential security issues).
Not impossible, you'd just need to have the different machines see/mount
the same file-system for starters.  That would result in coherent
binaries, no shipping required.  I've done this on an ancient x86 FreeBSD
cluster (8 to 16 machines) mounting a single file server before with no
hiccups.  (That was gcc-3.4.0, ccache 2.2, distcc 2.13, both old).

> So a distributed build has to also distribute files, for example by
> sharing a common distributed file system. OF course details are
> complex.

On a somewhat related note, I'd be interested to hear if ccache could be
snuck into bootstrapping to speed up recompiles in the intermediate
stages, especially with incremental changes.  (Anyone tried this?)  I've
noted that ccache-ing only speeds up the first stage, as one would expect.
There might be a subtle issue with ccache assuming that the compiler that
created a cache-hit object did not change.  I'm only aware of ccache
verifying compiler versions (string compare) in the hit-check, which alone
doesn't suffice to guarantee that the cache is (or should be) hit.

*sigh* Bootstrapping on me 5+ yr. old dual-G4 takes quite a while, even
with make -j2 (which helps a lot).  Wish-list: gcj-ccache for classpath
rebuild acceleration.

Fang

Reply via email to