GCC vs. Clang Benchmark Comparison At Varying Optimization Levels
Written by Michael Larabel in Software on 3 March 2016. Page 1 of 4. 15 Comments

Last week I posted various LLVM Clang and GCC compiler benchmarks using packages available on Ubuntu 16.04 LTS and with the testing from a Xeon Skylake system. Today are some complementary tests when benchmarking GCC 5.3.1 and LLVM Clang 3.8 while testing each compiler with a variety of different optimization levels.

Rather than testing GCC vs. Clang compilers with just one set of CFLAGS/CXXFLAGS, for this comparison I tested each of these open-source compilers with a variety of different optimization levels. GCC 5.3.1 and LLVM Clang 3.8 were each tested at -O0, -O1, -O2, -O2 -march=native, -O3, -O3 -march=native, and -Ofast -march=native.

The Xeon E3-1280 v5 "Skylake" quad-core CPU (plus Hyper Threading) with 3.7GHz base frequency and 4.0GHz turbo boost frequency was used for this latest round of compiler benchmarking. Thanks to MSI for loaning the Xeon processor used in this testing as well as sending over the MSI C236A Workstation board for Linux testing. Ubuntu 16.04 LTS x86_64 was running on this system with the Linux 4.4 kernel.

All of this compiler benchmarking was done in a fully-automated and repeatable manner using the open-source Phoronix Test Suite benchmarking software.

Related Articles

Trending Linux News