gcc3 ABI compatibility?
Ian Lance Taylor
iant@google.com
Sun Jun 8 01:12:00 GMT 2008
Michael VanLoon <michaelv@yahoo-inc.com> writes:
> On 6/5/08 7:15 AM, "Ian Lance Taylor" <iant@google.com> wrote:
>
>> Andrew Haley <aph@redhat.com> writes:
>>
>>> Probably. The multi-vendor C++ ABI made this a lot better, but there are
>>> still incompatibilities. We don't break ABI compatibility on release
>>> branches,
>>> so you can safely assume that 3.4.2 is compatible with 3.4.1.
>>
>> And across release branches, it is worth knowing about the
>> -fabi-version option.
>>
>> Ian
>
> That's very cool! I notice that gcc 4.0.1 (Darwin) gives the option of
> versions 0 through 2, where 2 is gcc 3.4 ABI version. Does this mean that
> gcc 4 uses the ABI from gcc 3.4?
Yes.
> Would this mean a library built with gcc
> 3.4.6, containing non-templatized C++ class interfaces, would successfully
> link into code built with gcc 4, especially if I specified -fabi-version=2?
Yes.
Ian
More information about the Gcc-help
mailing list