[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200709061155.46667.vda.linux@googlemail.com>
Date: Thu, 6 Sep 2007 11:55:46 +0100
From: Denys Vlasenko <vda.linux@...glemail.com>
To: Oleg Verych <olecom@...wer.upol.cz>
Cc: sam@...nborg.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 0/3] build system: section garbage collection for vmlinux
On Wednesday 05 September 2007 21:34, Oleg Verych wrote:
> > > > Build system: section garbage collection for vmlinux
> > >
> > > Maybe this is just a test suit to get finish with `make XYZ static`?
> >
> > They are vaguely connected in a sense that unused function which is
> > not marked static doesn't generate gcc warning, but will be discarded
> > by --gc-sections. "make XYZ static" also tends to find them - you make
> > function static, you recompile the file, and gcc informs you that
> > the function is not used at all!
> >
> > This happened to me when I did aic7xxx patches.
> >
> > You may yse --print-gc-sections to see the list of discarded sections.
>
> Anyway, this is gccism/binutilizm. That about other possible/future
> options?
>
> Give me example, please, why function must be non static if not used.
Where do you see I'm saying that they must be non-static?
I'm all for marking functions static. I just did it for aic7xxx.
> If usage requires kconfig tuning, then this is a better way to go,
We already do it, but we don't have enough developers to audit
every driver for every possible combination of config options.
As a result, there always be some amount of unused functions and data.
Using --gc-sections will discard that.
> than to adopt yet another GNU/Luxury.
Actually, this is how linkers should have worked long ago.
Borland's Turbo Pascal was doing it ten+ years ago.
I don't understand why you are opposed to toolchain helping
humans to get optimized result. But it's fine with me.
I won't force anyone to select CONFIG_DISCARD_UNUSED_SECTIONS.
--
vda
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists