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]

Re: Precompiled headers (or other speed ups)


<<<Skip this paragraph if your not interested in the details of my
situation.> I have a single source file that takes 5-7 min to compile
on my Pentium 133 64M RAM. The file uses the following libraries:
GTK--, MySQL++ and STL. Pre-processed the file is 1.2M and it
contains 423 classes. That's really big I know, but there ought to be
some way to at least bring down the compile time a bit.
>>

But why use such a slow obsolete machine for such a large project? That
seems a real mismatch to me. What would be interesting is to see how
fast your program compiles on a modern inexpensive machine (for under
$2K, you can get a gigahertz Athlon machine with 256 meg of memory).

Now, of course it is nice if things compile fast on your relatively slow
machine, and from a conceptual point of view, there is no reason why this
should not be the case (Realia COBOL would compile probably close to 
half a million lines a minute on your machine, and COBOL is quite a
complex language!). 

However, super fast compilation speed has never been a gcc goal. Early on
this was problematic, but our experience, at least in the GNAT world, is
that machines are getting fast enough that compilation time is not a
bottleneck for most folks, even though gcc may have got slower in absolute
terms.

Of course it is always worth smoking out bottlenecks, but I find the
compilation performance you report not unreasonable. Why on EARTH do
you have a single source file this long -- sounds like simply awful
programming style???

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