GCC & LLVM Clang Compiler Benchmarks On AMD's EPYC 7601
Written by Michael Larabel in Software on 26 September 2017. Page 1 of 6. 17 Comments

For squeezing maximum performance out of Linux systems with source-based workloads, most of you know there can often be tweaks to be had to the compiler stack for greater performance. As well with the never-ending advancements to the leading open-source code compilers, between releases can be measurable performance benefits but sometimes not without regressions too. With AMD's EPYC line-up still being very fresh and the underlying Zen microarchitecture (or "znver1" as referred to by the compiler toolchains), here are a variety of benchmarks under recent releases of the GCC and LLVM Clang compilers.

Up to now with our AMD EPYC Linux benchmarking has been focused on the GNU Compiler Collection (GCC), while for this article is also getting some LLVM Clang testing too. While GCC has offered Zen tuning since 2015 (and improved since then), only with the recent LLVM 5.0 did they introduce a proper Zen scheduler model. Already within the LLVM 6.0 development code AMD developers updated that znver1 scheduler model. LLVM 6.0 should be released in early 2018 as stable.

The compilers being compared for this EPYC benchmarking today were GCC 6.3.0 (as found out-of-the-box on Debian 9.1 Stretch that was used currently on this EPYC Tyan 2U server), GCC 7.2.0 as the GNU's latest compiler stable release, and a GCC 8.0.0 development snapshot for the current state of the compiler's development code as of last week. GCC 8 will be released as stable in the form of GCC 8.1 around the end of Q1'2018. On the LLVM Clang side was using the LLVM Clang 5.0 branch and then also the latest LLVM Clang 6.0 compiler code as of last week.

The compilers built from source were all done in their release, non-debugging mode. During this compiler comparison, tests were done while the CFLAGS/CXXFLAGS were set to "-O3 -march=native" for ensuring the resulting binaries are geared for optimal performance.

Following the GCC vs. Clang benchmark results are also some tests of just LLVM Clang 6.0 while testing different "-march=" values for seeing the benefits of znver1 specific tuning right now compared to earlier x86-64 microarchitectures.

All of these LLVM Clang / GCC compiler benchmarks were carried out in a fully-automated and reproducible manner using the open-source Phoronix Test Suite.



Related Articles
Trending Linux News