lkml.org 
[lkml]   [2005]   [Dec]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 00/15] Generic Mutex Subsystem
Linus Torvalds wrote:

> And don't get me wrong: if it's easier to just ignore the performance bug,
> and introduce a new "struct mutex" that just doesn't have it, I'm all for
> it. However, if so, I do NOT want to do the unnecessary renaming. "struct
> semaphore" should stay as "struct semaphore", and we should not affect old
> code in the _least_.
>

It would still be good to look at a fair mutex implementation first
IMO before making a choice to use unfair mutexes.

They'll often be held for longer than spinlocks so fairness may be
more important.

> Then code can switch to "struct mutex" if people want to. And if one
> reason for it ends up being that the code avoids a performance bug in the
> process, all the better ;)
>

Is this a good idea? Then we will have for a long time different
bits of code with exactly the same synchronisation requirements
using two different constructs that are slightly different. Not to
mention code specifically requiring semaphores would get confusing.

If we agree mutex is a good idea at all (and I think it is), then
wouldn't it be better to aim for a wholesale conversion rather than
"if people want to"?

--
SUSE Labs, Novell Inc.

Send instant messages to your online friends http://au.messenger.yahoo.com

-
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-12-20 09:05    [W:0.149 / U:0.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site