GCC: Difference between revisions

No edit summary
Useful flags: mention 10.1's -fanalyzer
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
==Useful flags==
* <tt>-fmax-errors=n</tt> print a maximum of n errors, 0 (the default) being unbounded
* <tt>-E</tt> to generate preprocessor output, <tt>-s</tt> to generate assembly output
* <tt>-fanalyzer</tt> (since 10.1) to do rich static analysis [https://clearlinux.org/blogs-news/major-improvements-gcc-101 ClearLinux blog]
==Optimization==
==Optimization==
* Use '''-Q -Ox --help=optimizers''' to determine which optimization flags are enabled for a given -Ox setting (or read the info pages).
* Use '''-Q -Ox --help=optimizers''' to determine which optimization flags are enabled for a given -Ox setting (or read the info pages).
Line 54: Line 59:
* [http://gcc.gnu.org/onlinedocs/gccint/ GNU Compiler Collection Internals]
* [http://gcc.gnu.org/onlinedocs/gccint/ GNU Compiler Collection Internals]
* [[Core]] files
* [[Core]] files
* [[Questions]]