Show Your Support: This site is primarily supported by advertisements. Ads are what have allowed this site to be maintained on a daily basis for the past 18+ years. We do our best to ensure only clean, relevant ads are shown, when any nasty ads are detected, we work to remove them ASAP. If you would like to view the site without ads while still supporting our work, please consider our ad-free Phoronix Premium.
Linux Developers Are Once Again Trying To Enable Intel FSGSBASE For Better Performance
These patches are about enabling FSGSBASE instruction usage for allowing reading and writing to the FS/GS BASE from any privilege level. There are performance benefits thanks to skipping a system call and MSR write and also register savings.
Last year was a fair amount of Linux kernel patches floating around on the FSGSBASE front, which was certainly welcome considering how context switching performance has been hammered in the past two years as a result of the various mitigations like Spectre and Meltdown.
There were patches for this FSGSBASE Linux support towards the end of last year but then all fell silent without the code being merged and seemingly held up by awaiting feedback from GDB debugger developers.
Microsoft's Sasha Levin is now trying to get the work back on track. He revived the latest mailing list thread in hopes of seeing some action and getting any remaining questions/issues sorted out so it could be mainlined. Why would Microsoft's prominent Linux kernel engineer care? Presumably over maximizing performance in their Azure cloud given more than half of those instances are running Linux and especially with the hits encountered since 2018 as a result of the speculative execution vulnerabilities.
Intel's Andi Kleen meanwhile reaffirmed today, "Nothing breaks, and it's a nice improvement for context switch performance, in NMI/PMU performance, and also gives user space two free registers to play around with."
Here's to hoping the Intel FSGSBASE support for Linux can get squared away this year -- hopefully now for the Linux 5.8 cycle. Meanwhile Intel Ivy Bridge as the first processors with FSGSBASE support are marking eight years since launch later this month.