GCC 13 vs. Clang 17 Compiler Benchmarks, Early Clang 18 & GCC 14 Development Benchmarks
As it's been a while since last delivering any competitive GCC versus LLVM Clang compiler competitive analysis and with the year quickly drawing a close, here's a fresh look at the GCC vs. Clang C/C++ compiler performance of various resulting application binaries tested on x86_64. GCC 13 vs. Clang 17 were tested as what's readily available on Ubuntu 23.10 Linux plus a look ahead in using the latest GCC 14 and LLVM Clang 18 development snapshots as of this week.
As part of the various end-of-year articles, this article is providing a fresh look at the GCC vs. Clang performance of the generated binaries on x86_64. GCC 13.2, LLVM Clang 17.0.2, LLVM Clang 18.0.0 Git as of 23 December, and GCC 14.0.0 Git as of 23 December were all tested in their release form on Ubuntu 23.10. The same CFLAGS/CXXFLAGS were maintained the same throughout all of the testing with just swapping out the compiler being used. This is intended to provide some reference figures for those curious about the friendly performance between these two leading open-source C?C++ compilers.