From: Eric Sandeen <sandeen@redhat.com> Date: Tue, 8 Jul 2008 15:27:34 -0500 Subject: [fs] noinline_for_stack attribute Message-id: 4873CDB6.8000608@redhat.com O-Subject: [PATCH RHEL5 7/9] noinline_for_stack attribute Bugzilla: 443896 RH-Acked-by: Jeff Moyer <jmoyer@redhat.com> RH-Acked-by: Jeff Layton <jlayton@redhat.com> RH-Acked-by: Alexander Viro <aviro@redhat.com> This is for: Bugzilla Bug 443896: RFE: [Ext4 enabler] backport vfs helpers to facilitate ext4 backport and testing From: Andrew Morton <akpm@linux-foundation.org> Date: Tue, 4 Mar 2008 22:28:40 +0000 (-0800) Subject: add noinline_for_stack X-Git-Tag: v2.6.25-rc4~70 X-Git-Url: http://git.engineering.redhat.com/?p=linux-2.6.git;a=commitdiff_plain;h=735c4fb916e9f83a9350aeb2680d77d01ea75094 add noinline_for_stack People are adding `noinline' in various places to prevent excess stack consumption due to gcc inlining. But once this is done, it is quite unobvious why the `noinline' is present in the code. We can comment each and every site, or we can use noinline_for_stack. Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> diff --git a/include/linux/compiler.h b/include/linux/compiler.h index 78e57bb..f48079c 100644 --- a/include/linux/compiler.h +++ b/include/linux/compiler.h @@ -132,6 +132,12 @@ extern void __chk_io_ptr(void __iomem *); #define noinline #endif +/* + * Rather then using noinline to prevent stack consumption, use + * noinline_for_stack instead. For documentaiton reasons. + */ +#define noinline_for_stack noinline + #ifndef __always_inline #define __always_inline inline #endif