Translations:GCC optimization/44/en

From Gentoo Wiki
Jump to:navigation Jump to:search
  • -O3: enables -O2 as well as optimizations that are expensive in terms of compile time and memory usage. Compiling with -O3 is likely to improve performance (although not guaranteed). While historically -O3 could expose compiler bugs, nowadays issues with -O3 are almost always instances of undefined behavior (UB) and the code is at fault and should be fixed. Some packages are still known-broken with -O3. Using -O3 is not recommended unless running test suites for packages.