This is the mail archive of the
libstdc++@sourceware.cygnus.com
mailing list for the libstdc++ project.
Re: enabling -O2 with gcc 2.96 and later
"Martin v. Loewis" <martin@loewis.home.cs.tu-berlin.de> writes:
| > No offense intended, but so is this second attempt, IMHO :-)
| >
| > How about:
| >
| > AC_EGREP_CPP([ok], [
| > #if (__GNUC__ == 2 && __GNUC_MINOR__ > 95) || __GNUC__ > 2
| > ok
| > #fi
| > ], [OPTLEVEL='-O2'], [OPTLEVEL=])
| > AC_SUBST(OPTLEVEL)
|
| I did not follow this closely, but I think checking version numbers in
| autoconf is morally wrong.
Please, can you expand on this?
| ... What is the reason not to use -O2 in
| earlier versions? Something is miscompiled?
Compiling v-3 with gcc-2.95.2 -g -O2 produces an ICE.
-- Gaby