Skip to contentSkip to conversation

'sticky pages' support in the VM, futex-2.5.38-C5

PATCH Ingo Molnar 2 participants 2 messages Sep 26, 2002 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 3 lines · Linus Torvalds

This patch seems trivially broken by having two futexes on the same page. When the first futex removes itself, it will clear the sticky bit, even though the other futex is still pinning the same page.

sigh. And we cannot even properly detect which unpin_page() was the last unpinning of the page - there can be so many other reasons a page's count is elevated. And keeping a page sticky forever is no solution either, the number of sticky pages would increase significantly, causing real fork() problems.

Quoted 1 line

Trust me, you'll have to use the page list approach.

yeah, will try that now. I'm a bit worried about the mandatory cross-CPU TLB flushes though.

Ingo

#2 lore raw
Quoted 4 lines · Ingo Molnar
Quoted 1 line

Trust me, you'll have to use the page list approach.

yeah, will try that now. I'm a bit worried about the mandatory cross-CPU TLB flushes though.

Wouldn't splitting the vm area also be cleaner - that would let you get things like correct address space accounting too.