2000-10-27 20:31:59

by Pavel Machek

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

Hi!

> > if the person who sent you the -pre4 patch against module.c
> > had Cc:'ed this mailing list then your kernel would do
> > something useful when compiled with gcc-2.7.2.3.
>
> It seems that gcc-2.7.2.3 is terminally ill. I'd rather change
> Documentation/Changes, and just document the fact.
>
> These kinds of subtle work-arounds for gcc bugs are not really acceptable,
> nor is it worthwhile complaining when somebody does development with a gcc
> that is _not_ broken, and doesn't notice that some random gcc bug breaks
> the kernel for others.

Would it be possible to keep 2.7.2.3? You still need 2.7.2.3 to
reliably compile 2.0.X (and maybe even 2.2.all-but-latest?).
Pavel
--
I'm [email protected]. "In my country we have almost anarchy and I don't care."
Panos Katsaloulis describing me w.r.t. patents at [email protected]


2000-10-27 20:46:59

by Alan

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

> Would it be possible to keep 2.7.2.3? You still need 2.7.2.3 to
> reliably compile 2.0.X (and maybe even 2.2.all-but-latest?).

There has only been one know egcs 1.1 build problem found in the last 9
months or so (the fpu emu one). I really dont think using egcs 1.1.2 to build
2.2 kernels is a problem. In fact its probably the default nowdays

2000-10-28 01:01:16

by Keith Owens

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

On Fri, 27 Oct 2000 19:45:13 +0200,
Pavel Machek <[email protected]> wrote:
>Would it be possible to keep 2.7.2.3? You still need 2.7.2.3 to
>reliably compile 2.0.X (and maybe even 2.2.all-but-latest?).

You can have multiple versions of gcc installed, just select the one to
use when you compile the kernel.

CC=gcc-2723 make 2.0 kernel
CC=gcc-2723 make 2.2 kernel
CC=egcs make 2.4 kernel

2000-10-28 11:16:20

by Dominik Kubla

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

On Sat, Oct 28, 2000 at 12:00:43PM +1100, Keith Owens wrote:
> On Fri, 27 Oct 2000 19:45:13 +0200,
> Pavel Machek <[email protected]> wrote:
> >Would it be possible to keep 2.7.2.3? You still need 2.7.2.3 to
> >reliably compile 2.0.X (and maybe even 2.2.all-but-latest?).
>
> You can have multiple versions of gcc installed, just select the one to
> use when you compile the kernel.
>
> CC=gcc-2723 make 2.0 kernel
> CC=gcc-2723 make 2.2 kernel
> CC=egcs make 2.4 kernel

Even simpler: "gcc -V 2.7.2.3" or "gcc -V 2.95.2" or whatever...

Yours,
Dominik Kubla
--
http://petition.eurolinux.org/index_html - No Software Patents In Europe!

2000-10-29 00:28:08

by Richard Henderson

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

On Sat, Oct 28, 2000 at 01:15:58PM +0200, Dominik Kubla wrote:
> Even simpler: "gcc -V 2.7.2.3" or "gcc -V 2.95.2" or whatever...

Which was a nice idea, but it doesn't actually work. Changes
in spec file format between versions makes this fall over.


r~

2000-10-29 15:09:45

by Dominik Kubla

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

On Sat, Oct 28, 2000 at 05:27:00PM -0700, Richard Henderson wrote:
> On Sat, Oct 28, 2000 at 01:15:58PM +0200, Dominik Kubla wrote:
> > Even simpler: "gcc -V 2.7.2.3" or "gcc -V 2.95.2" or whatever...
>
> Which was a nice idea, but it doesn't actually work. Changes
> in spec file format between versions makes this fall over.

Wow. So much for reading the manual... well, that's considered
cheating anyway, isn't it?

Dominik
--
http://petition.eurolinux.org/index_html - No Software Patents In Europe!

2000-10-29 23:24:37

by Rusty Russell

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

In message <[email protected]> you write:
> On Fri, 27 Oct 2000 19:45:13 +0200,
> Pavel Machek <[email protected]> wrote:
> >Would it be possible to keep 2.7.2.3? You still need 2.7.2.3 to
> >reliably compile 2.0.X (and maybe even 2.2.all-but-latest?).
>
> You can have multiple versions of gcc installed, just select the one to
> use when you compile the kernel.
>
> CC=gcc-2723 make 2.0 kernel
> CC=gcc-2723 make 2.2 kernel
> CC=egcs make 2.4 kernel

No, environment doesn't override make variables by default. This
works on any shell:

make CC=egcs <targets>

Rusty.
--
Hacking time.

2000-10-30 11:06:34

by Peter Samuelson

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)


[rth]
> > Which was a nice idea, but it doesn't actually work. Changes
> > in spec file format between versions makes this fall over.

[Dominik Kubla]
> Wow. So much for reading the manual... well, that's considered
> cheating anyway, isn't it?

I know this was true at one time -- egcs couldn't read 2.7 spec files,
or something like that. (I remember at the time thinking "so much for
the great and glorious '-V' theory".)

But I think it's since been fixed:

$ gcc -v
Reading specs from /usr/lib/gcc-lib/i386-linux/2.95.2/specs
gcc version 2.95.2 20000220 (Debian GNU/Linux)
$ gcc -V2.7.2.3 -v
Reading specs from /usr/lib/gcc-lib/i386-linux/2.7.2.3/specs
gcc driver version 2.95.2 20000220 (Debian GNU/Linux) executing gcc version 2.7.2.3

Is there more subtle breakage?

Peter

2000-10-30 11:09:04

by Peter Samuelson

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)


[Rusty]
> > CC=gcc-2723 make 2.0 kernel
> > CC=gcc-2723 make 2.2 kernel
> > CC=egcs make 2.4 kernel
>
> No, environment doesn't override make variables by default. This
> works on any shell:
>
> make CC=egcs <targets>

If you're going to get pedantic, that won't work either -- since the
makefiles in kernels 2.0 and 2.2 expect $(CC) to include some compiler
flags. This was fixed somewhere in 2.3.3x.

Peter

2000-10-30 11:26:17

by Linux Kernel Developer

[permalink] [raw]
Subject: Recommended compiler? - Re: [patch] kernel/module.c (plus gratuitous rant)

So which is the recommended compiler for each kernel version 2.2.x,
2.4.x(pre?) nowadays? I've pretty much kept gcc 2.7.2.3 around just for
compiling the kernel however now I hear you need egcs to compile 2.4? I
don't mind keeping 2.7.2.3 around in its own installation directory just for
the purpose of doing kernel work however from a previous post I've now got
the impression that egcs has become the recommended compiler? If I'm going
to keep a secondary compiler around (outside of gcc 2.95.2 which I still
hear is no good for kernel compiles) just for kernel work I'd prefer to use
my disk space on the recommended one.

>
> [Rusty]
> > > CC=gcc-2723 make 2.0 kernel
> > > CC=gcc-2723 make 2.2 kernel
> > > CC=egcs make 2.4 kernel
> >
> > No, environment doesn't override make variables by default. This
> > works on any shell:
> >
> > make CC=egcs <targets>
>
> If you're going to get pedantic, that won't work either -- since the
> makefiles in kernels 2.0 and 2.2 expect $(CC) to include some compiler
> flags. This was fixed somewhere in 2.3.3x.
>
> Peter
> -


2000-10-30 11:59:27

by Peter Samuelson

[permalink] [raw]
Subject: Re: Recommended compiler? - Re: [patch] kernel/module.c (plus gratuitous rant)


> So which is the recommended compiler for each kernel version 2.2.x,
> 2.4.x(pre?) nowadays?

* 2.91.66 aka egcs 1.1.2. It has been officially blessed for 2.4 and
has been given an informal thumbs-up by Alan for 2.2. (It does NOT
work for 2.0, if you still care about that.)

* 2.7.2.3 works for 2.2 (and 2.0) but NOT for 2.4.

* 2.95.2 seems to work with both 2.2 and 2.4 (no known bugs, AFAIK) and
many of us use it, but it is a little riskier than egcs.

* Red Hat "2.96" or CVS 2.97 will probably break any known kernel.

Peter

2000-10-30 12:55:47

by Martin Dalecki

[permalink] [raw]
Subject: Re: Recommended compiler? - Re: [patch] kernel/module.c (plus gratuitous rant)

Peter Samuelson wrote:
>
> > So which is the recommended compiler for each kernel version 2.2.x,
> > 2.4.x(pre?) nowadays?
>
> * 2.91.66 aka egcs 1.1.2. It has been officially blessed for 2.4 and
> has been given an informal thumbs-up by Alan for 2.2. (It does NOT
> work for 2.0, if you still care about that.)
>
> * 2.7.2.3 works for 2.2 (and 2.0) but NOT for 2.4.
>
> * 2.95.2 seems to work with both 2.2 and 2.4 (no known bugs, AFAIK) and
> many of us use it, but it is a little riskier than egcs.
>
> * Red Hat "2.96" or CVS 2.97 will probably break any known kernel.

Works fine for me and 2.4.0-test10-pre5... however there are tons of
preprocessor warnings in some drivers.

2000-10-30 18:51:20

by Richard Henderson

[permalink] [raw]
Subject: Re: [patch] kernel/module.c (plus gratuitous rant)

On Mon, Oct 30, 2000 at 05:05:43AM -0600, Peter Samuelson wrote:
> But I think it's since been fixed:

No.

> Is there more subtle breakage?

Yes.


r~

2000-10-30 20:52:38

by Horst H. von Brand

[permalink] [raw]
Subject: Re: Recommended compiler? - Re: [patch] kernel/module.c (plus gratuitous rant)

Martin Dalecki <[email protected]> said:
> Peter Samuelson wrote:

[...]

> > * Red Hat "2.96" or CVS 2.97 will probably break any known kernel.

> Works fine for me and 2.4.0-test10-pre5... however there are tons of
> preprocessor warnings in some drivers.

CVS (from 20001028 or so) gave a 2.4.0.10.6/i686 that crashed on boot, no
time to dig deeper yet.
--
Dr. Horst H. von Brand mailto:[email protected]
Departamento de Informatica Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria +56 32 654239
Casilla 110-V, Valparaiso, Chile Fax: +56 32 797513

2000-10-30 22:04:23

by Jakub Jelinek

[permalink] [raw]
Subject: Re: Recommended compiler? - Re: [patch] kernel/module.c (plus gratuitous rant)

On Mon, Oct 30, 2000 at 05:50:07PM -0300, Horst von Brand wrote:
> Martin Dalecki <[email protected]> said:
> > Peter Samuelson wrote:
>
> [...]
>
> > > * Red Hat "2.96" or CVS 2.97 will probably break any known kernel.
>
> > Works fine for me and 2.4.0-test10-pre5... however there are tons of
> > preprocessor warnings in some drivers.
>
> CVS (from 20001028 or so) gave a 2.4.0.10.6/i686 that crashed on boot, no
> time to dig deeper yet.

CVS 2.97 is known to miscompile e.g. buffer.c.

Jakub

2000-10-31 09:35:18

by Martin Dalecki

[permalink] [raw]
Subject: Re: Recommended compiler? - Re: [patch] kernel/module.c (plus gratuitous rant)

Horst von Brand wrote:
>
> Martin Dalecki <[email protected]> said:
> > Peter Samuelson wrote:
>
> [...]
>
> > > * Red Hat "2.96" or CVS 2.97 will probably break any known kernel.
>
> > Works fine for me and 2.4.0-test10-pre5... however there are tons of
> > preprocessor warnings in some drivers.
>
> CVS (from 20001028 or so) gave a 2.4.0.10.6/i686 that crashed on boot, no
> time to dig deeper yet.

I was just using the compiler shipped by RedHat with all the fixes
contained
therein.... self compiled under glibc-2.1.95 on a system which some long
time
ago was RedHat-5.1 ;-). And it worked.