More FUTEX2 Bits Land In The Linux 6.7 Kernel
Last week's locking set of changes for the Linux 6.7 kernel add new interfaces for the FUTEX2 system call ABI. This work is making FUTEX2 more extendable and addressing some of the prior limitations.
New is sys_futex_wake() to complement the existing sys_futex_waitv(). The sys_futex_wake() can be used to wake a number of futexes.
Also complementing sys_futex_waitv() is now sys_futex_wait() for waiting on a futex. It's identical to the traditional FUTEX_WAIT_BITSET op but now part of the FUTEX2 family of calls.
Further rounding out the FUTEX2 family in Linux 6.7 is adding a sys_futex_requeue(). This new call requeues a waiter from one futex to another. The new sys_futex_requeue() accepts an array of the source and destination futexes and is similar to the prior FUTEX_CMP_REQUEUE operation but is now brought into the FUTEX2 world.
A FUTEX2_NUMA flag is also added to the FUTEX2 flags in preparing for the planned NUMA extension around FUTEX2.
FUTEX2 was originally worked on for improving FUTEX for addressing Linux gaming needs.
Aside from the FUTEX2 work, the locking changes for Linux 6.7 bring a number of micro-optimizations around locking primitives in the kernel. It will be interesting to see if these locking optimizations bring any measurable performance changes but from an initial look over doesn't appear to be the case.There are also debugging improvements and real-time locking improvements as part of the pull request.
See this pull for all of the locking updates in Linux 6.7.
New is sys_futex_wake() to complement the existing sys_futex_waitv(). The sys_futex_wake() can be used to wake a number of futexes.
Also complementing sys_futex_waitv() is now sys_futex_wait() for waiting on a futex. It's identical to the traditional FUTEX_WAIT_BITSET op but now part of the FUTEX2 family of calls.
Further rounding out the FUTEX2 family in Linux 6.7 is adding a sys_futex_requeue(). This new call requeues a waiter from one futex to another. The new sys_futex_requeue() accepts an array of the source and destination futexes and is similar to the prior FUTEX_CMP_REQUEUE operation but is now brought into the FUTEX2 world.
A FUTEX2_NUMA flag is also added to the FUTEX2 flags in preparing for the planned NUMA extension around FUTEX2.
FUTEX2 was originally worked on for improving FUTEX for addressing Linux gaming needs.
Aside from the FUTEX2 work, the locking changes for Linux 6.7 bring a number of micro-optimizations around locking primitives in the kernel. It will be interesting to see if these locking optimizations bring any measurable performance changes but from an initial look over doesn't appear to be the case.There are also debugging improvements and real-time locking improvements as part of the pull request.
See this pull for all of the locking updates in Linux 6.7.
5 Comments