C++ ABI Issues

Joe Buck Joe.Buck@synopsys.com
Tue Aug 27 12:09:00 GMT 2002


> > It seems that even if it does, we can preserve libstdc++'s binary
> > compatibility by adding a dummy field that exactly fills up any padding.
> > This will make no difference in 3.2, and will force any compiler correctly
> > implementing the ABI to match the 3.2 interface.
> 
> Sorr for jumping into discussion, but :0
> What exactly will this bring us?  libstdc++ is not only C++ library installed
> in the system and it is one of the most easilly upgardable when reinstalling
> compiler?

But we don't want to have to bump the major version number, forcing people
to have two library copies if they need to run old binaries.  We want the
new libstdc++ to work with old binaries, meaning that it supports the same
ABI.

We'd have to tell people how to do the same for all other libraries
(e.g. KDE).  That is, this would be a methodology, just like avoiding
returning structs in C was the way to go in the old days (because it
triggered ABI differences between gcc and some proprietary compilers).

Hopefully this will be needed in very few places.  If we're very lucky it
won't be needed at all.



More information about the Gcc mailing list