Re: Trying to understand the -fabi-version=n and -fabi-compat-version=n options

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Nov 27, 2019 at 5:10 AM Dallman, John <john.dallman@xxxxxxxxxxx>
wrote:

> > > 1. Compile code as if the compiler were GCC 4.8, doing the mangling
> with
> > the /new/ ABI of GCC 4.8.
> > >
> > > 2. Provide aliases for symbols the compiler creates, as if it were GCC
> 3.2 to
> > 4.9 with the /traditional/ ABI.
> > >
> > > How wrong am I?
> >
> > You are correct.
>
> Wow!
>
> > -fabi-compat-version with the same version number as -fabi-version has no
> > effect.
>
> Presumably, this is because -fabi-version is already producing the symbols
> with that mangling? Seems obvious now I look at it that way.
>

Though actually, given the default behavior mentioned below, this will have
the effect of preventing compatibility aliases.

> That does make sense.  But it might be simpler for everyone to just use
> > -fabi-version=2 now, and later =N, without messing with -fabi-compat-
> > version.
>
> OK. There ... might be issues with some of the more ego-driven groups over
> that.
>
> > By default, if the user specifies -fabi-version, the compiler will
> generate
> > compatibility aliases for the most current version for
> forward-compatibility.
>
> To make sure I understand this, if I'm using a compiler whose native ABI
> is, say, 7, and I specify -fabi-version=2 and no -fabi-compat-version=N
> option, that means I get the ABI 2 versions of the symbols, from the
> option, and the ABI 7 versions of the symbols from this default?
>

Correct.

Jason




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux