Search notes:

gcc --help

gcc --help={class|[^]qualifier}[,…] …
--help can be preceeded with -Q which alters the descriptive text: instead of describing options, it indicates the value of the respective option (its value or if it is enabled or disabled).

Classes

optimizers Display all of the optimization options supported by the compiler.
warnings Display all of the options controlling warning messages produced by the compiler (see gcc -W)
target Display target-specific options. Unlike the --target-help option however, target-specific options of the linker and assembler are not displayed. This is because those tools do not currently support the extended --help= syntax.
params Display the values recognized by the --param option.
language Display the options supported for language, where language is the name of one of the languages supported in this version of GCC. If an option is supported by all languages, one needs to select common class
common Display the options that are common to all languages.

Qualifiers

undocumented Display only those options that are undocumented.
joined Display options taking an argument that appears after an equal sign in the same continuous piece of text, such as --help=target.
separate Display options taking an argument that appears as a separate word following the original option, such as -o output-file.

Examples

Display all undocumented target-specific options

$ gcc --help=target,undocumented
The following options are target specific:
  -mcet-switch                Turn on CET instrumentation for switch statements that use a jump table and an indirect jump.
  -mcpu=                      Same as -mtune=.  Uses of this option are diagnosed.
  -mfused-madd                Same as -ffp-contract=fast (or, in negated form, -ffp-contract=off).  Uses of this option are diagnosed.
  -mintel-syntax              Same as -masm=intel (or, in negated form, -masm=att).  Uses of this option are diagnosed.
  -mno-align-stringops        This option lacks documentation.
  -mno-fancy-math-387         This option lacks documentation.
  -mno-push-args              This option lacks documentation.
  -mno-red-zone               This option lacks documentation.
  -msse5                      Same as -mavx.  Uses of this option are diagnosed.

Show default and changed value

On my machine, the default value for -march is x86-64:
$ gcc -Q --help=target | grep -- '-march=  '
  -march=                               x86-64
By setting -march=native, the value of -march changes to skylake:
$ gcc -march=native -Q --help=target | grep -- '-march=  '
  -march=                               skylake

See also

GCC options such as --target-help

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1759421684, '216.73.216.42', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/languages/C-C-plus-plus/GCC/options/help(90): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78