On 11/23/05, Linus Torvalds <[email protected]> wrote:
It _should_ be fairly easy to do something like that - just a simple
global flag that gets set and makes CPL3 ignore lock prefixes.
This is a goof rist step. But the effectiveness will descrease
significantly in the near future. It can only work for
single-threaded processes without writable shared memory.
With the growing number of cores/threads the need to use parallelism
rises. With techniques like OpenMP the threshold to do this is
lowered significantly. The process-model, so much preferred on this
list over the thread model, requires shared memory, therefore also
eliminating the effectiveness of this functionality.
A real solution needs to be more fine grained. It is often known in
the userland code whether the specific word which is accessed using
atomic ops really can be shared. The POSIX interfaces, for instance,
require that all mutexes etc which are placed in shared memory are
attributed as such. Combine this with the knowledge about the number
of threads in use and the result is that even with writable shared
memory segments the lock prefix can be avoided. There are a whole
bunch of cases where we already do conditional locking. It's just
plain ugly and not as efficient as we would like i t.
So, implementing control with per-userlevel context will se rapidly
diminishing success and I'm wondering whether it is better to go for
something with a bit finer level of control.
--
➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]