Mail Archives: djgpp/2002/06/04/07:27:07
On 4 Jun 2002 at 10:22, CBFalconer wrote:
> Having gotten this installed, and having removed GCC 2.953, I have
> recompiled a few things unchanged, and am observing the following:
>
> 1) It is showing up failure to #include <string.h> here and there
> when using strlen and strcmp. Good.
gcc-2.95.X permitted to use strlen(), strcmp() and some other functions
without declaration. gcc-3.0.X and gcc-3.1 no more permits that.
> 2) The executables are a little bit smaller, compiled with
> gstabs+. However after passing through strip the executables are
> somewhat larger. Don't know why.
My experience shows that both -gcoff (read -g) and -gstabs+ are
often near to unusable with many C++ programs which uses
STL. -gdwarf-2 seems to behave better (at least with GDB-5.2).
So maybe it's time to switch to -gdwarf-2 as the default soon?
The size of executable with debug info seriously increases when
-gdwarf-2 is being used.
> 3) All versions were compiled with O2. Looking at the generated
> code with "objdump -dS" it appears as if the optimization is quite
> different. Many lumps seem to be relegated to "final" code
> outside the purvey of the source. This may be related to 2)
About warnings generated by gcc-3.1: I often use '-W -Wall -Werror'
in my code and usually this forced to do some changes to use a new versions,
but not too much.
Andris
- Raw text -