This is the mail archive of the
mailing list for the GCC project.
RE: gcc compile-time performance
- From: dewar at gnat dot com (Robert Dewar)
- To: gcc at gcc dot gnu dot org, james at westongold dot com
- Date: Tue, 21 May 2002 21:26:21 -0400 (EDT)
- Subject: RE: gcc compile-time performance
> Many organisations develop and test using -g
> and no optimisation, and then release what they've
> tested, symbols and all. And why not? As soon
> as you do database IO, most bets are off.
> Most real business apps will use a database,
> or communicate with something else, or otherwise
> be bound in system calls (eg select).
Note that if you really intend to use -O0 to deliver, then the design of
gcc is quite unfortunate. The amount of code generated by gcc with optimization
off compares really poorly with other competing compilers. It really is very
cheap to do at least a little cleaning up of code. To see in x86 code
repeated cases of a variable being stored and immediately loaded from the
same location is sad.
We find almost none of our users delivering in -O0. If this is really a
pattern in other uses, then I think that's another reason for looking
at a -O0.5 which would try to do at least a little optimziation. I am not
even sure this would not speed things up, since you would generate smaller
(speed things up = speed up compilation)