New Linux System Call Proposed To Let User-Space Pin Themselves To Specific CPU Cores
Written by Michael Larabel in Linux Kernel on 22 January 2020 at 05:23 AM EST. 32 Comments
LINUX KERNEL --
A "pin_on_cpu" system call has been proposed for the Linux kernel as a new means of letting user-space threads pin themselves to specific CPU cores.

User-space processes requesting to be run on specific CPU cores can already e done by the likes of Linux's sched_setaffinity to get/set the CPU affinity mask while pin_on_cpu would be a new and simpler way. The current calls also run into issues around CPU hot-plugging, as explained further in the RFC mailing list post.

Setting the CPU core to run on with the proposed pin_on_cpu system call would still require that the specific CPU be part of the allowed CPU mask. The pin_on_cpu proposal is being made as part of furthering along the Restartable Sequences (RSEQ) support. But obviously there are plenty of other use-cases for a simple means of letting user-space processes pin to specific CPU cores themselves.

More details on this CPU thread pinning system call proposal via the kernel mailing list while waiting to see if it takes off for flight or not.
Related News
About The Author
Author picture

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter or contacted via MichaelLarabel.com.

Popular News This Week