GCC Benchmarks At Varying Optimization Levels With Core i9 10900K Show An Unexpected Surprise

Written by Michael Larabel in Software on 27 July 2020 at 10:07 AM EDT. Page 4 of 4. 59 Comments.

The AOM-AV1 video encoder performance also was hit sharply on GCC 10 with -O2. Most of the time I am running compiler tests is focused on -O3 or -O3 -march=native, which may explain why previous tests didn't show such degraded performance.

The x265 performance was also quite bad with GCC 10's -O2 optimization level.

The main takeaway from this round of testing was that for many -- but not all tests -- the "-O2" optimization level led to severely degraded performance at least for this Core i9 10900K system.

The "-O3 -march=native" and "-O3 -march=native -flto" performance wasn't all that interesting in this testing, but the main takeaway is that "-O2" is much slower on the latest GCC 10 code. As for why, I haven't seen any explanation yet but will be firing off more benchmarks to see if it's isolated to this system/microarchitecture or something else going awry.

If you enjoyed this article consider joining Phoronix Premium to view this site ad-free, multi-page articles on a single page, and other benefits. PayPal or Stripe tips are also graciously accepted. Thanks for your support.


Related Articles
About The Author
Michael Larabel

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 20,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, LinkedIn, or contacted via MichaelLarabel.com.