Commit ce920983 authored by Andrew Morton's avatar Andrew Morton Committed by David S. Miller

[PATCH] Add noinline attribute

From: Andi Kleen <ak@muc.de>

This patch adds the `noinline' function attribute.  It can be used to
explicitly tell the compiler to not inline functions.

We need this due to what is, IMO, a bug present in gcc-3.4 and current
gcc-3.5 CVS: the compiler is inlining init/main.c:rest_init() inside
init/main.c:start_kernel(), despite the fact that thay are declared to be
placed in different text sections.
parent b882d444
......@@ -21,3 +21,7 @@
#define __attribute_pure__ __attribute__((pure))
#define __attribute_const__ __attribute__((__const__))
#if __GNUC_MINOR__ >= 1
#define noinline __attribute__((noinline))
#endif
......@@ -96,6 +96,10 @@
# define __attribute_const__ /* unimplemented */
#endif
#ifndef noinline
#define noinline
#endif
/* Optimization barrier */
#ifndef barrier
# define barrier() __memory_barrier()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment