Thomas Munro <thomas.mu...@gmail.com> writes: > Whenever I run into this, or my Mac requires manual ipcrm to clean up > leaked SysV kernel junk, I rebase my patch for sema_kind = 'futex'. > Here it goes. It could be updated to support NetBSD I believe, but I > didn't try as its futex stuff came out later.
FWIW, I looked at a nearby NetBSD 10.0 machine. It has /usr/include/sys/futex.h, which includes this enticing comment: /* * Definitions for the __futex(2) synchronization primitive. * * These definitions are intended to be ABI-compatible with the * Linux futex(2) system call. */ However, the complete lack of any user-level documentation makes me misdoubt the extent of their commitment to this :-( I have the same concern about depending on undocumented macOS APIs. Other than that, getting off of SysV semaphores would be a nice thing to do. regards, tom lane