lkml.org 
[lkml]   [2001]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Pls apply this spinlock patch to the kernel

On Sat, 3 Nov 2001, Richard Henderson wrote:
>
> On Sat, Nov 03, 2001 at 12:20:53PM -0800, Linus Torvalds wrote:
> > If you have a 4-byte entry that is aligned to 128 bytes, you have 124
> > bytes of stuff that the linker _will_ fill up with other things.
>
> If you put the alignment on the type, not the variable, e.g.

That doesn't work.

The whole _point_ here is to make the thing variable-specific, so that we
can say _this_ spinlock needs a cache-line of its own, without blowing up
all spinlocks to 128 bytes.

There's no way we want 128-byte spinlocks in general. We want to mark 4-5
spinlocks as being so critical that they can have a cacheline of their
own. But I do _not_ want to have special operations for those spinlocks,
so I don't want those spinlocks to have any special types (ie the actual
_user_ should not need to care, so that you can play around with testing
the different spinlocks one by one without having to edit all the users of
any specific spinlock).

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:12    [W:0.043 / U:0.316 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site