This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: using distcc to speed up GCC bootstraps


On Feb 19, 2004, law@redhat.com wrote:

> I don't see how it would be all that much of a hack.  But I've certainly
> never looked at distcc.

What distcc does is:

run compiler driver for preprocessing, with -E -o tmpfile
send command line and tmpfile to remote distcc
distccd runs command line with tmpfile, producing outfile
distccd sends outfile back
distcc stores outfile in expected output object file

> Basically it seems to me all you need to do is ship across the referenced
> source and the command line -- for java that's all you need

Not in the distcc case.  In our particular case, because of the
requirement to have access to the build tree in order to run the
compiler, we probably also have access to the libjava build tree.  But
we don't necessarily have access to the source tree.

> (ie, pretend the original source file is already preprocessed and I
> would think it would "just work".)

It's not that simple.  There's a lot of state that the Java compiler
gets from other files in the class search path, that are not present
in the Java source that we'd send to the remote compiler should we do
it like that.

Some of the state is also affected by the current working directory,
and since not even distccrel makes all pathnames in command line flags
network-neutral, and since distccd runs all compilations from within
its own temporary directory, compilations might produce different
results, or simply fail.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Happy GNU Year!                     oliva@{lsd.ic.unicamp.br, gnu.org}
Red Hat GCC Developer                 aoliva@{redhat.com, gcc.gnu.org}
Free Software Evangelist                Professional serial bug killer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]