OpenMandriva Is Finding Great Success In Their Switch To Using LLVM's Clang Compiler
Written by Michael Larabel in LLVM on 28 April 2019 at 02:25 AM EDT. 60 Comments
LLVM --
OpenMandriva remains among the few Linux distributions using the LLVM Clang compiler by default where possible in place of the GCC compiler. While at times it's difficult in maintaining this combination, they continue to find great success in using Clang as their default compiler.

OpenMandriva developer Bernhard Rosenkränzer presented at this month's EuroLLVM conference on their use of LLVM Clang by default where nearly all Linux distributions remain with the GNU Compiler Collection.

Their most prominent reasons for using Clang over GCC are for better compile times, a smoother cross-compilation experience, benefiting from the sanitizers and other tooling built around LLVM/Clang, and more readable code is (arguably) generated. OpenMandriva developers have also found less breakage with using LLVM/Clang even when using snapshots of the latest compiler state, which they tend to shift over to early in their development cycles knowing the six-month release cadence of LLVM.

But the pain points shared during EuroLLVM 2019 were LLVM/Clang still missing RISC-V architecture support so there they are relying upon GCC. They also encounter issues with many projects not testing against anything but GCC and some projects even being hostile towards building with Clang. There is also the possibility of missed optimizations when there are pre-processor macros going strictly for the GNU route.

Of more than twenty-thousand OpenMandriva packages, just around 139 currently have Clang-related patches while 327 have to rely upon GCC.

Those interested in learning more about OpenMandriva's usage of LLVM/Clang as the default system compiler can do so via this PDF slide deck from EuroLLVM while we await this year's video recordings.
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 10,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.

Related LLVM News
Popular News This Week