rustix icon indicating copy to clipboard operation
rustix copied to clipboard

Split `futex` into separate functions

Open sunfishcode opened this issue 3 years ago • 0 comments

Rustix's futex function can perform several different operations, as determined by a FutexOperation argument. However, as documented in the Arguments section of Linux's man page, in some operations, some of the arguments are unused. We should consider splitting futex into multiple functions, one per signature at least, so that we can provide customized signatures for each operation.

A related crate in this space is the linux-futex crate. Another option here would be to simply port linux-futex to use rustix's existing low-level futex API internally.

sunfishcode avatar Feb 04 '22 00:02 sunfishcode