On Tue, Jun 05, 2007 at 11:20:22AM +0200, Arnd Bergmann wrote:
> On Tuesday 05 June 2007, Vegard Nossum wrote:
> > > You also need to take some care about the gcc arguments that you pass.
> > > E.g. passing -DMODULE when building the precompiled header means that
> > > you can't use that .pch when you build a file where you don't pass
> > > -DMODULE.
> > 
> > So does it make sense to build two precompiled headers (one with
> > CFLAGS_KERNEL, one with CFLAGS_MODULE), and then pass -include
> > kernel.h.gch and -include module.h.gch for kernel/built-in modules and
> > loadable modules, respectively? I think I'll try it out and see how it
> > goes.
> Yes, that sounds reasonable. But you should check also the other gcc
> options, e.g. KBUILD_MODNAME is defined in a different way for every
> module. Consequently, you must not include any header that uses
> this symbol when building your .gch files.

It's stuff like this that worries me..
In the kernel we rely on a lot of things - more than in usual projects.
And one thing we have established in the 2.6 kernel is a trust in the
build system. If you change something kbuild will recompile
everything needed to build a consistent kernel.
Whatever we do for precompiled headers shall keep the promise
and the trust in kbuild.

But any speedup in a kernel build is welcome so please continue
your effort but keep an eye out for all the details.


This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
kbuild-devel mailing list

Reply via email to