[lkml]   [2003]   [May]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [patch] futex requeueing feature, futex-requeue-2.5.69-D3

On Thu, 22 May 2003, Martin Wirth wrote:

> - Specify the futexes to be mm-local: By using the pair mm* and vaddr as
> key it is possible to have process local futexes living on the same
> hash with the following advantages:
> 1. no page_table lock contention (I implemented mm-local futexes
> for my application after I noticed long latencies on SMP where a
> high prio tasks spun in futex_wake while another task was doing
> mmap/munmap on a second processor).
> 2. no vcache pollution (I guess 99% of all futexes will not be in
> shared memory)
> 3. Slightly faster, since no page pinning is needed

there's a patch in the works to change futex hashing to not require page
pinning, without making futexes process-local. This should also fix the
FUTEX_FD problems.

basically the idea is that struct page remains to be a good hash whenever
the page is present, and the swapout pte value is a good hash key when the
page is swapped out. So we basically can make futexes swappable.

this gets rid of pinned pages and pagetable locking, without the need for
API-level changes.

> By the way, your latest futex patch still contains the bogus if
> (!list_empty(&q.list)) conditional, that's always true since you hold
> the locks at this point and no one can have removed us from the list:

ok, i'll fix this! I knew i missed something ...


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

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