Merged overnight to the LLVM/Clang compiler’s codebase was initial targeting for next-generation AMD Zen 6 processors using the znver6 target.
Back in December was the initial GNU Compiler Collection enablement with -march=znver6 support merged for GCC 16. That GCC 16.1 stable release will be out in March~April with that initial AMD Zen 6 compiler support. Now overnight the similar enablement has landed within the LLVM/Clang Git codebase. The main Git code for LLVM is currently tracking for what will become LLVM/Clang 23 with a stable release in September. It’s also possible this Znver6 enablement will be back-ported to the upcoming LLVM/Clang 22 stable series. The back-porting of new CPU targets has happened before for LLVM and with LLVM/Clang 22 stable not coming out until later in February, it’s very well possible it will happen here with Znver6.
While -march=znver6 is now working in LLVM/Clang, the current LLVM code doesn’t yet support Zen 6’s new AVX-512 BMM bit manipulation instructions. That will come in a later patch. AVX-512 BMM allows for bit matrix multiply and bit reversal operations.
This commit is what landed that AMD Zen 6 support overnight in LLVM.
Compared to the past where AMD didn’t get out their open-source compiler support until right around product launch time or even after, it’s great seeing this Zen 6 support make it out well in advance this time. Especially with GCC’s long release cycles and even with LLVM/Clang being on a six-month release cadence and it not being clear yet if it will get approved for back-porting to LLVM 22, at least LLVM 23 will be out in September that will still likely be ahead of the new Ryzen and EPYC processors launching.
As one caveat, for now Zen 6 is still relying on the Zen 5 tuning information. Hopefully AMD gets out the proper instruction tuning/cost tables for Zen 6 in a timely manner still for making it into the next compiler releases. The belated tuning / cost tables remains one area where the AMD compiler support tends to lag behind.
Meanwhile over on the graphics side of the house, AMD yesterday added the GFX1170 “RDNA 4m” target to LLVM with the AMDGPU back-end.
