GCC 3.2 Release Series — Changes, New Features, and Fixes
GCC 3.2 Release Series Changes, New Features, and Fixes
The latest release in the 3.2 release series is
GCC 3.2.3.
Caveats and New Features
Caveats
The C++ compiler does not correctly zero-initialize
pointers-to-data members. You must explicitly initialize
them. For example: int S::*m(0);
will work, but depending on default-initialization to zero
will not work. This bug cannot be fixed in GCC 3.2 without
inducing unacceptable risks. It will be fixed in GCC 3.3.
This GCC release is based on the GCC 3.1 sourcebase, and thus has
all the changes in the GCC 3.1
series. In addition, GCC 3.2 has a number of C++ ABI fixes
which make its C++ compiler generate binary code which is incompatible
with the C++ compilers found in earlier GCC releases, including GCC 3.1
and GCC 3.1.1.
Frontend Enhancements
C/C++/Objective-C
The method of constructing the list of directories to be searched
for header files has been revised. If a directory named by a
-I option is a standard system include directory,
the option is ignored to ensure that the default search order
for system directories and the special treatment of system header
files are not defeated.
The C and Objective-C compilers no longer accept the "Naming
Types" extension (typedef foo = bar); it was
already unavailable in C++. Code which uses it will need to
be changed to use the "typeof" extension instead:
typedef typeof(bar) foo. (We have removed this
extension without a period of deprecation because it has
caused the compiler to crash since version 3.0 and no one
noticed until very recently. Thus we conclude it is not in
widespread use.)
C++
GCC 3.2 fixed serveral differences between the C++ ABI implemented
in GCC and the multi-vendor standard, but more have been found
since the release. 3.2.1 adds a new warning, -Wabi,
to warn about code which is affected by these bugs.
We will fix these bugs in some future release, once we are
confident that all have been found; until then, it is our intention
to make changes to the ABI only if they are necessary for correct
compilation of C++, as opposed to conformance to the ABI
documents.
For details on how to build an ABI compliant compiler for
GNU/Linux systems, check the common C++ ABI
page.
New Targets and Target Specific Improvements
IA-32
Fixed a number of bugs in SSE and MMX intrinsics.
Fixed common compiler crashes with SSE instruction set enabled
(implied by -march=pentium3, pentium4,
athlon-xp)
__m128 and __m128i is not 128bit
aligned when used in structures.
x86-64
A bug whereby the compiler could generate bad code for
bzero has been fixed.
ABI fixes (implying ABI incompatibilities with previous version in some
corner cases)
3.2.3 is a bug fix release only; there are no new features that
were not present in GCC 3.2.2.
Bug Fixes
This section lists the problem reports (PRs) from GCC's bug tracking
system that are known to be fixed in the 3.2.3 release. This
list might not be complete (that is, it is possible that some PRs
that have been fixed are not listed here), and some of the titles have been
changed to make them more clear.
Internal Compiler Errors (multi-platform)
3782: (c++) -quiet -fstats produces a segmentation fault in cc1plus
Beginning with 3.2.2, GCC's Makefile suite supports redirection of
make install by means of the DESTDIR
variable. Parts of the GCC tree have featured that support long
before, but now it is available even from the top level.
Other than that, GCC 3.2.2 is a bug fix release only; there are no
new features that were not present in GCC 3.2.1.
Bug Fixes
On the following i386-based systems GCC 3.2.1 broke the C ABI wrt.
functions returning structures: Cygwin, FreeBSD (GCC 3.2.1 as shipped
with FreeBSD 5.0 does not have this problem), Interix, a.out-based GNU/Linux
and NetBSD, OpenBSD, and Darwin. GCC 3.2.2 reverts this ABI change, and
thus restores ABI-compatibility with previous releases (except GCC 3.2.1)
on these platforms.
This section lists the problem reports (PRs) from GCC's bug tracking
system that are known to be fixed in the 3.2.2 release. This
list might not be complete (that is, it is possible that some PRs
that have been fixed are not listed here) and some of the titles have been
changed to make them more clear.
Internal Compiler Errors (multi-platform)
5919: (c++) ICE when passing variable array to template function
7129: (c++) ICE with min/max assignment operators (<?= and >?=)
7507: ICE with -O2 when address of called function is a complicated expression
7622: ICE with nested inline functions if function's address is taken
7681: (fortran) ICE in compensate_edge, in reg-stack.c (also PR 9258)
8031: (c++) ICE in code comparing typeids and casting from virtual base
3.2.1 adds a new warning, -Wabi. This option warns when GNU
C++ generates code that is known not to be binary-compatible with the
vendor-neutral ia32/ia64 ABI. Please consult the GCC manual, included in the
distribution, for details.
This release also removes an old GCC extension, "naming types", and the
documentation now directs users to use a different GCC extension,
__typeof__, instead. The feature had evidently been broken for a
while.
Otherwise, 3.2.1 is a bug fix release only; other than bug fixes and the
new warning there are no new features that were not present in GCC 3.2.
In addition, the previous fix for
PR 7445
(poor performance of std::locale::classic() in multi-threaded
applications) was reverted ("unfixed"), because the "fix" was not
thread-safe.
Bug Fixes
This section lists the problem reports (PRs) from GCC's bug tracking
system that
are known to be fixed in the 3.2.1 release. This list might not be complete
(that is, it is possible that some PRs that have been fixed are not listed
here). As you can see, the number of bug fixes is quite large, so it is
strongly recommended that users of earlier GCC 3.x releases upgrade to
GCC 3.2.1.
Internal Compiler Errors (multi-platform)
2521: (c++) ICE in build_ptrmemfunc, in cp/typeck.c
5661: (c++) ICE instantiating template on array of unknown size (bad code)
6419: (c++) ICE in make_decl_rtl for "longest" attribute on 64-bit platforms
3.2 is a small bug fix release, but there is a change to the application
binary interface (ABI), hence the change to the second part of the version
number.
The main purpose of the 3.2 release is to correct a couple of problems in
the C++ ABI, with the intention of providing a stable interface going
forward. Accordingly, 3.2 is only a small change to 3.1.1.