Re: C: inline without forcing?

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

 



On Wed, Jun 02, 2021 at 12:22:58PM -0400, Danielle Church wrote:
> On Wed, Jun 2, 2021 at 11:54 AM Segher Boessenkool
> <segher@xxxxxxxxxxxxxxxxxxx> wrote:
> > > Is there no way to get the code-emit behavior (inline the
> > > function or emit a TU-external reference, don't emit standalone
> > > definition) without the optimizer changes (more likely to inline the
> > > function, even if it's a bad idea)?
> >
> > extern attribute((gnu_inline))
> 
> Does ``extern inline attribute((gnu_inline))'' behave appreciably
> differently than C99's bare ``inline''? They seem to have the same
> effect from the documentation, though with reversed semantics for the
> presence vs absence of the extern keyword.

Neither GNU inline nor standard C inline is inclusive of the other.  A
gnu_inline extern inline is never emitted as a standalone function.


Segher



[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