* Alpha: replacing "extern inline"
@ 2006-08-20 23:54 Adrian Bunk
2006-08-21 21:55 ` Richard Henderson
0 siblings, 1 reply; 3+ messages in thread
From: Adrian Bunk @ 2006-08-20 23:54 UTC (permalink / raw)
To: rth; +Cc: linux-kernel
I want to get rid of all "extern inline" in the kernel.
Why?
"extern inline" generates a warning with -Wmissing-prototypes and I'm
currently working on getting the kernel cleaned up for adding this to
the CFLAGS since it will help us to avoid a nasty class of runtime
errors.
"extern inline" was required at the times when
__attribute__((always_inline)) wasn't avalable.
Nowadays, we use "static inline", and if there are places that really
need a forced inline, we use "static __always_inline".
Can someone tell me which of the Alpha "static inline"'s need for some
reason an __always_inline?
And a related question:
Does the never defined __IO_EXTERN_INLINE still have any purpose?
cu
Adrian
--
Gentoo kernels are 42 times more popular than SUSE kernels among
KLive users (a service by SUSE contractor Andrea Arcangeli that
gathers data about kernels from many users worldwide).
There are three kinds of lies: Lies, Damn Lies, and Statistics.
Benjamin Disraeli
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Alpha: replacing "extern inline"
2006-08-20 23:54 Alpha: replacing "extern inline" Adrian Bunk
@ 2006-08-21 21:55 ` Richard Henderson
2006-08-23 22:53 ` Adrian Bunk
0 siblings, 1 reply; 3+ messages in thread
From: Richard Henderson @ 2006-08-21 21:55 UTC (permalink / raw)
To: Adrian Bunk; +Cc: linux-kernel
On Mon, Aug 21, 2006 at 01:54:38AM +0200, Adrian Bunk wrote:
> Why?
Because it inlines when it needs to, and does not generate
out of line code when its address is taken.
> Can someone tell me which of the Alpha "static inline"'s need for some
> reason an __always_inline?
There shouldn't be any.
> Does the never defined __IO_EXTERN_INLINE still have any purpose?
It is defined.
$ grep 'define __IO_EXTERN_INLINE' * | wc -l
12
r~
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Alpha: replacing "extern inline"
2006-08-21 21:55 ` Richard Henderson
@ 2006-08-23 22:53 ` Adrian Bunk
0 siblings, 0 replies; 3+ messages in thread
From: Adrian Bunk @ 2006-08-23 22:53 UTC (permalink / raw)
To: linux-kernel
On Mon, Aug 21, 2006 at 02:55:26PM -0700, Richard Henderson wrote:
> On Mon, Aug 21, 2006 at 01:54:38AM +0200, Adrian Bunk wrote:
> > Why?
>
> Because it inlines when it needs to, and does not generate
> out of line code when its address is taken.
Ah, I start to remember.
Is this actually used anywhere in the kernel?
> > Can someone tell me which of the Alpha "static inline"'s need for some
> > reason an __always_inline?
>
> There shouldn't be any.
>
> > Does the never defined __IO_EXTERN_INLINE still have any purpose?
>
> It is defined.
>
> $ grep 'define __IO_EXTERN_INLINE' * | wc -l
> 12
Ups, I was blind...
> r~
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2006-08-23 22:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-08-20 23:54 Alpha: replacing "extern inline" Adrian Bunk
2006-08-21 21:55 ` Richard Henderson
2006-08-23 22:53 ` Adrian Bunk
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox