Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sun, 9 Sep 2012 23:12:01 +0100
From: Justin Cormack <>
Subject: Re: capset() capget() syscalls

On Sun, Sep 9, 2012 at 10:55 PM, Rich Felker <> wrote:
> With something like futex that's a trivial syscall, I'm not sure what
> qualifies it for a separate lib rather than inclusion in libc. The
> library would be <20 bytes of code on most archs... That's not to say
> I think we have to expose it in musl, but I think using a separate
> library (especially if there's any chance of it being built as a .so
> rather than just .a) is a worse choice than just writing
> syscall(SYS_futex, ...) in your source...

The manpage says

       To reiterate, bare futexes are not intended as an easy-to-use
abstraction for end-users.  (There
       is no wrapper function for this system call in glibc.)
Implementors are expected to be assembly
       literate and to have read the sources of the futex userspace
library referenced below.

I thought (from memory) the non-contended case required architecture
specific assembly, the syscall just dealt with contended case. So the
library needs to provide the other stuff to make it usable. Its not a
lot, and must be there to use these for threading I guess, but doesnt
have standard names?


Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.