AMD Developers Looking At GNU C Library Platform Optimizations For Zen
Written by Michael Larabel in AMD on 25 March 2020 at 08:18 AM EDT. 48 Comments
AMD --
It's long overdue but AMD engineers are now looking at refactoring the GNU C Library (Glibc) platform support to enhance the performance for AMD Zen processors.

Stemming from Glibc semantics that effectively "cripple AMD" in just checking for Intel CPUs while AMD CPUs with Glibc are not even taking advantage of Haswell era CPU features, AMD developers are now looking at properly plumbing AMD Zen platform support into this important C library for Linux users.

Under a "request for comments" flag, patches tentatively posted add AMD Zen and AVX/AVX2 platform support and refactor the platform support within the CPU features detection. This would at run-time allow CPU features like AVX2, FMA, BMI2, POPCNT, and other instructions to be enabled when detected to be running on an AMD Zen based processor. There are also fall-backs for "generic" AVX2 and then AVX CPUs for older CPUs.

The patches are currently under discussion with some upstream GNU toolchain developers providing their recommendations on how they would like to see this more diverse platform support handled.


Hopefully this Glibc support for AMD Zen can be sorted out in short order and mainlined. It's a pity that it has taken this long to get sorted out but it's nice to see the recent uptick in AMD's Linux/open-source patches particularly around these fundamental improvements/optimizations. It's also too bad this didn't start a few months earlier so it could have stood chances for seeing such an improved library within the likes of the upcoming Ubuntu 20.04 LTS release that will see many AMD EPYC server deployments.


It looks like the surge in AMD CPU sales, expanding EPYC cloud deployments, and continuing super-computer contract wins that are principally Linux based are at least in part helping to foster some of this open-source work. It's not that the GNU C Library has been intentionally thwarting AMD CPUs but rather Intel developers for years have invested heavily in toolchain improvements and other areas of GNU/Linux to take advantage of their latest CPU microarchitectures. Meanwhile AMD has traditionally contributed much less to these upstream projects directly but that is fortunately now changing. Going back years to when Intel was punctually hitting their CPU release schedules on time, even then they would generally have out their new compiler/toolchain optimizations upstreamed well ahead of those product launches for ensuring good launch-day customer support on Linux.
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