[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200709051455.05508.vda.linux@googlemail.com>
Date: Wed, 5 Sep 2007 14:55:05 +0100
From: Denys Vlasenko <vda.linux@...glemail.com>
To: sam@...nborg.org
Cc: kai@...maschewski.name, linux-kernel@...r.kernel.org
Subject: [PATCH 3/3] build system: section garbage collection for vmlinux
On Wednesday 05 September 2007 14:49, Denys Vlasenko wrote:
> On Wednesday 05 September 2007 14:47, Denys Vlasenko wrote:
> > On Wednesday 05 September 2007 14:43, Denys Vlasenko wrote:
> > > These patches fix section names and add
> > > CONFIG_DISCARD_UNUSED_SECTIONS. It is not enabled
> > > unconditionally because only newest binutils have
> > > ld --gc-sections which is stable enough for kernel use.
> > > IOW: this is an experimental feature for now.
> >
> > Part 1: fix section names over entire source (all arches).
>
> Part 2: fix x86_64 vdso linker script to not produce
> broken vdso image with gcc -ffunction-sections -fdata-sections.
Part 3:
Makefile:
init/Kconfig:
add config DISCARD_UNUSED_SECTIONS with appropriate
big scary warning. It enables gcc and ld options
for section garbage collection.
arch/x86_64/kernel/vmlinux.lds.S:
include/asm-generic/vmlinux.lds.h:
add KEEP and SORT_BY_ALIGNMENT directives, as needed.
arch/frv/Makefile:
had half-baked option similar to DISCARD_UNUSED_SECTIONS,
replace it.
DISCARD_UNUSED_SECTIONS=n should be safe for all arches.
DISCARD_UNUSED_SECTIONS=y is usable only for x86_64 at the moment.
--
vda
View attachment "linux-2.6.23-rc4.3.gc.patch" of type "text/x-diff" (15679 bytes)
Powered by blists - more mailing lists