On 13 June 2011 10:44, Franck Z wrote: > Hello, > > I would like to ask the developpers' community about an idea that interests > me these days. > > It comes from the fact that the compilation time when I try to run the > "make" command on the source code for gcc is too long for the configuration > I use. Indeed, I enjoy the flexibility of USB keys in order to "play with > gcc" when I get the occasion. Therefore, as I have access to Windows based > systems, I opted for a Cygwin installation and a svn download of gcc trunk > on a USB key which I can plug in in all freedom. > > Of course, it's slower than if I used a hard drive, but even then it takes a > lot of time, and so much disk access that I fear for my local hard drive > (I'm jocking here, of course!). Moreover, I guess that many "amateur" > developpers of open-source projects could share my opinion.
Are you configuring gcc with --enable-checking=release? If not then building from svn trunk enables lots of additional checking which slows the compiler down considerably. You can also use --disable-bootstrap if you just want to build a native gcc and don't need a 3-stage bootstrap. > Therefore, I would like to ask you about the idea of turning the "gcc" > command into an intelligent agent, with respects to the disk usage and the > recompilations of headers that have a lot of impact on my way of using > "make". I think there are simpler solutions than yours that are already being worked on. You don't mention them, so I don't know if you're aware of http://ccache.samba.org and http://distcc.org Have you looked at PPH and PTH? http://gcc.gnu.org/wiki/pph > From what I imagine, I would change both "make" and "gcc" so that some > serialization of what different invokations of "gcc" performs is available > throughout the execution of the "make" command. > > At first, I thought of serializing "per se" objects that "gcc" would use, > but I observed that the branch in the gcc project which aimed at rewriting > the gcc source code in C++ is no longer active. The branch "incremental > compilation", from what I understand, seems besides to take a different > approach. The gcc-in-cxx branch is no longer active because the changes were integrated into trunk, so gcc can be compiled with a c++ compiler now. I don't think it would help for your idea anyway, data structures don't need to be represented as C++ objects in order to be serialized.