You could create unpriviledged 'disable interrupts for 10
instructions' and 'test if interrupts are still disabled'
instructions, and base your mutex implementation on that.
But you'll have to stop calling it futex at that point...
Or you could just optimize syscalls to be really fast...
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--