Re: [PATCH 2/7] x86: Add an option to compile with -ffunction-sections -fdata-sections

From: Rusty Russell
Date: Wed Feb 04 2009 - 03:38:56 EST


On Saturday 06 December 2008 10:33:55 Jeff Arnold wrote:
> From: Waseem Daher <wdaher@xxxxxxx>
>
> This patch makes it possible to link and boot an x86 kernel with
> -ffunction-sections and -fdata-sections enabled.

Nice:
text data bss dec hex filename
3575210 361820 319488 4256518 40f306 vmlinux-with-sections
3579626 364892 323584 4268102 412046 vmlinux-no-sections

> +config FUNCTION_DATA_SECTIONS
> + bool "Compile with -ffunction-sections -fdata-sections"
> + depends on !FTRACE
> + help
> + If you say Y here the compiler will give each function
> + and data structure its own ELF section.

You need to make this depend on X86, otherwise allmodconfig will turn it on
and break other archs.

What's the conflict with FTRACE?

Thanks,
Rusty.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/