Re: 2.1.114 fails build on i386

Horst von Brand (vonbrand@inf.utfsm.cl)
Tue, 04 Aug 1998 16:58:23 -0400


"Michael H. Warfield" <mhw@alcove.wittsend.com> said:
> Linus Torvalds enscribed thusly:
> > Use this instead (or rather, in _addition_ to the patch David suggested).
>
> > It fixes the problem at a negligible cost in size, but I much prefer
> > losing a few bytes of memory than to have different code for SMP or not
> > SMP.
>
> Well... Close... It fixed one problem for me (the Sig11) but
> left me with this:

[...]

> [Patch defining spinlocks as non-empty on UP]

Any idea how much other structures grow by this? Any other possible bad
effects? Copying stuff around needlessly? Head scratching on the part of
our hacker children who just don't understand what the contents of a
spinlock_t is all about?

Note that to have empty structures is allowed in GNU C (it's not ANSI), and
works fine elsewhere in the kernel (surely this is not exactly the only
structure with a spinlock in it in the whole source). egcs works fine with
this stuff, from day one (or almost). Sooner or later we'll switch to a new
compiler. Why add gratuituous burden for the sake of a obsolescent, broken
compiler? Sure, fix things up for the time being, but don't overdo it. A
possibility is what I proposed yesterday: Document the brokenness and the
kludge around. Or define spinlocks as non-empty for gcc-2.7.2.3's sake. But
don't stuff them forever without need! Getting rid of this just will haunt
us later.

Just my not so humble opinion.

-- 
Dr. Horst H. von Brand                       mailto:vonbrand@inf.utfsm.cl
Departamento de Informatica                     Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria              +56 32 654239
Casilla 110-V, Valparaiso, Chile                Fax:  +56 32 797513

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html