news about default kernel compliers

Kelledin kelledin+LFS at
Mon Jun 23 17:21:07 PDT 2003

On Monday 23 June 2003 11:54 am, Steve Prior wrote:
> I was wondering about compilers and Red Hat 8.0 - they seem to
> use gcc 3.2 and I thought that was a no no for recompiling the
> kernel, but they have no special notes (or an alternative
> compiler) about doing so.  Does anyone know if it is really OK
> to rebuild a kernel with this level of the compiler?

It depends on the platform.  I would guesstimate that it's OK for 
x86 at this point, and the kernel developers are just being 
ultra-conservative in recommending 2.95.3 for x86.

That recommendation doesn't apply to all platforms, though, and 
IIRC the kernel docs state that quite clearly.  On some non-x86 
platforms, gcc3 is kind of a necessity to build a kernel.  On 
Alpha, gcc-2.95.3 has a habit of ICEing when compiling SMP 
kernels.  And for AMD64, I don't think gcc-2.x even exists...

Oh, also: make sure your kernel and modules are ALL compiled by 
the same compiler.  A gcc2-compiled kernel will oops quite 
rapidly under load if you insmod gcc3-compiled modules, and I'm 
betting the reverse (gcc3-compiled kernel+gcc2-compiled modules) 
is also true.  IIRC modutils now has code to detect such 
mismatches and complain, but once upon a time it did not!

"If a server crashes in a server farm and no one pings it, does 
it still cost four figures to fix?"
Unsubscribe: send email to listar at
and put 'unsubscribe lfs-dev' in the subject header of the message

More information about the lfs-dev mailing list