diff options
author | Ingo Molnar <mingo@elte.hu> | 2007-02-22 03:38:22 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-26 15:53:30 -0500 |
commit | 25165120f2432ffa36518d53bd3ec66f6e434f63 (patch) | |
tree | 7ef036d734cb14579040d2825bdf30a9a24daca5 | |
parent | 38bed5429987c939d86cd3da915d6706fd1e6e53 (diff) |
[PATCH] x86: add -freg-struct-return to CFLAGS
Jeremy Fitzhardinge suggested the use of -freg-struct-return, which does
structure-returns (such as when using pte_t) in registers instead of on
the stack.
that is indeed so, and this option reduced the kernel size a bit:
text data bss dec hex filename
4799506 543456 3760128 9103090 8ae6f2 vmlinux.before
4798117 543456 3760128 9101701 8ae185 vmlinux.after
the resulting kernel booted fine on my testbox. Lets go for it.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | arch/i386/Makefile | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/i386/Makefile b/arch/i386/Makefile index f7ac1aea1d8a..bd28f9f9b4b7 100644 --- a/arch/i386/Makefile +++ b/arch/i386/Makefile | |||
@@ -31,7 +31,7 @@ LDFLAGS_vmlinux := --emit-relocs | |||
31 | endif | 31 | endif |
32 | CHECKFLAGS += -D__i386__ | 32 | CHECKFLAGS += -D__i386__ |
33 | 33 | ||
34 | CFLAGS += -pipe -msoft-float -mregparm=3 | 34 | CFLAGS += -pipe -msoft-float -mregparm=3 -freg-struct-return |
35 | 35 | ||
36 | # prevent gcc from keeping the stack 16 byte aligned | 36 | # prevent gcc from keeping the stack 16 byte aligned |
37 | CFLAGS += $(call cc-option,-mpreferred-stack-boundary=2) | 37 | CFLAGS += $(call cc-option,-mpreferred-stack-boundary=2) |