]> gcc.gnu.org Git - gcc.git/blame - gcc/common.opt
lex.c (warn_about_normalization): Cast field width to int to avoid warning.
[gcc.git] / gcc / common.opt
CommitLineData
d7b42618 1; Options for the language- and target-independent parts of the compiler.
50431bc4 2
cd280abb 3; Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc.
d7b42618
NB
4;
5; This file is part of GCC.
6;
7; GCC is free software; you can redistribute it and/or modify it under
8; the terms of the GNU General Public License as published by the Free
9; Software Foundation; either version 2, or (at your option) any later
10; version.
11;
12; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
13; WARRANTY; without even the implied warranty of MERCHANTABILITY or
14; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15; for more details.
16;
17; You should have received a copy of the GNU General Public License
18; along with GCC; see the file COPYING. If not, write to the Free
19; Software Foundation, 59 Temple Place - Suite 330, Boston, MA
20; 02111-1307, USA.
21
7b086b11 22; See c.opt for a description of this file's format.
d7b42618
NB
23
24; Please try to keep this file in ASCII collating order.
25
d185d268
NB
26-help
27Common
cf03fd63 28Display this information
d185d268 29
903caebf
NB
30-param
31Common Separate
744e6f33 32--param <param>=<value> Set parameter <param> to value. See below for a complete list of parameters
903caebf 33
d185d268
NB
34-target-help
35Common
36
37-version
38Common
39
40G
7b086b11 41Common Joined Separate UInteger
cf03fd63 42-G<number> Put global and static data smaller than <number> bytes into a special section (on some targets)
d185d268 43
903caebf
NB
44O
45Common JoinedOrMissing
cf03fd63 46-O<number> Set optimization level to <number>
903caebf
NB
47
48Os
49Common
cf03fd63 50Optimize for space rather than speed
903caebf
NB
51
52W
53Common RejectNegative
28786366 54This switch is deprecated; use -Wextra instead
903caebf 55
e01cc6dc 56Waggregate-return
50431bc4 57Common Var(warn_aggregate_return)
28786366 58Warn about returning structures, unions or arrays
e01cc6dc
NB
59
60Wcast-align
50431bc4 61Common Var(warn_cast_align)
28786366 62Warn about pointer casts which increase alignment
e01cc6dc
NB
63
64Wdeprecated-declarations
50431bc4 65Common Var(warn_deprecated_decl) Init(1)
28786366 66Warn about uses of __attribute__((deprecated)) declarations
e01cc6dc
NB
67
68Wdisabled-optimization
50431bc4 69Common Var(warn_disabled_optimization)
28786366 70Warn when an optimization pass is disabled
e01cc6dc
NB
71
72Werror
50431bc4 73Common Var(warnings_are_errors)
28786366 74Treat all warnings as errors
e01cc6dc 75
903caebf
NB
76Wextra
77Common
cf03fd63 78Print extra (possibly unwanted) warnings
903caebf 79
c65a01af 80Wfatal-errors
50431bc4 81Common Var(flag_fatal_errors)
c65a01af
RG
82Exit on the first error occurred
83
e01cc6dc 84Winline
50431bc4 85Common Var(warn_inline)
28786366 86Warn when an inlined function cannot be inlined
e01cc6dc
NB
87
88Wlarger-than-
89Common RejectNegative Joined UInteger
cf03fd63 90-Wlarger-than-<number> Warn if an object is larger than <number> bytes
e01cc6dc
NB
91
92Wmissing-noreturn
50431bc4 93Common Var(warn_missing_noreturn)
28786366 94Warn about functions which might be candidates for __attribute__((noreturn))
e01cc6dc
NB
95
96Wpacked
50431bc4 97Common Var(warn_packed)
28786366 98Warn when the packed attribute has no effect on struct layout
e01cc6dc
NB
99
100Wpadded
50431bc4 101Common Var(warn_padded)
28786366 102Warn when padding is required to align structure members
e01cc6dc
NB
103
104Wshadow
50431bc4 105Common Var(warn_shadow)
28786366 106Warn when one local variable shadows another
e01cc6dc
NB
107
108Wstrict-aliasing
109Common
28786366 110Warn about code which might break strict aliasing rules
e01cc6dc 111
5399d643
JW
112Wstrict-aliasing=
113Common Joined UInteger
114Warn about code which might break strict aliasing rules
115
e01cc6dc 116Wswitch
50431bc4 117Common Var(warn_switch)
28786366 118Warn about enumerated switches, with no default, missing a case
e01cc6dc
NB
119
120Wswitch-default
50431bc4 121Common Var(warn_switch_default)
28786366 122Warn about enumerated switches missing a \"default:\" statement
e01cc6dc
NB
123
124Wswitch-enum
50431bc4 125Common Var(warn_switch_enum)
28786366 126Warn about all enumerated switches missing a specific case
e01cc6dc
NB
127
128Wsystem-headers
50431bc4 129Common Var(warn_system_headers)
f3fdaec4 130Do not suppress warnings from system headers
e01cc6dc
NB
131
132Wuninitialized
50431bc4 133Common Var(warn_uninitialized)
28786366 134Warn about uninitialized automatic variables
e01cc6dc
NB
135
136Wunreachable-code
50431bc4 137Common Var(warn_notreached)
28786366 138Warn about code that will never be executed
e01cc6dc 139
903caebf
NB
140Wunused
141Common
cf03fd63 142Enable all -Wunused- warnings
903caebf 143
e01cc6dc 144Wunused-function
50431bc4 145Common Var(warn_unused_function)
28786366 146Warn when a function is unused
e01cc6dc
NB
147
148Wunused-label
50431bc4 149Common Var(warn_unused_label)
28786366 150Warn when a label is unused
e01cc6dc
NB
151
152Wunused-parameter
50431bc4 153Common Var(warn_unused_parameter)
28786366 154Warn when a function parameter is unused
e01cc6dc
NB
155
156Wunused-value
50431bc4 157Common Var(warn_unused_value)
28786366 158Warn when an expression value is unused
e01cc6dc
NB
159
160Wunused-variable
50431bc4 161Common Var(warn_unused_variable)
28786366 162Warn when a variable is unused
e01cc6dc 163
d185d268
NB
164aux-info
165Common Separate
cf03fd63 166-aux-info <file> Emit declaration information into <file>
d185d268
NB
167
168aux-info=
169Common Joined
170
171auxbase
172Common Separate
173
174auxbase-strip
175Common Separate
176
177d
178Common Joined
cf03fd63 179-d<letters> Enable dumps from specific passes of the compiler
d185d268
NB
180
181dumpbase
182Common Separate
cf03fd63 183-dumpbase <file> Set the file basename to be used for dumps
d185d268 184
31b66477
KC
185; The version of the C++ ABI in use. The following values are allowed:
186;
187; 0: The version of the ABI believed most conformant with the C++ ABI
188; specification. This ABI may change as bugs are discovered and fixed.
189; Therefore, 0 will not necessarily indicate the same ABI in different
190; versions of G++.
191;
192; 1: The version of the ABI first used in G++ 3.2.
193;
194; Additional positive integers will be assigned as new versions of
195; the ABI become the default version of the ABI.
57782ad8 196fabi-version=
50431bc4 197Common Joined UInteger Var(flag_abi_version) Init(2)
57782ad8 198
6ff3a151 199falign-functions
50431bc4 200Common Report Var(align_functions,0)
f3fdaec4 201Align the start of functions
6ff3a151 202
058de654
NB
203falign-functions=
204Common RejectNegative Joined UInteger
205
6ff3a151 206falign-jumps
50431bc4 207Common Report Var(align_jumps,0)
f3fdaec4 208Align labels which are only reached by jumping
6ff3a151 209
058de654
NB
210falign-jumps=
211Common RejectNegative Joined UInteger
212
6ff3a151 213falign-labels
50431bc4 214Common Report Var(align_labels,0)
f3fdaec4 215Align all labels
6ff3a151 216
058de654
NB
217falign-labels=
218Common RejectNegative Joined UInteger
219
6ff3a151 220falign-loops
50431bc4 221Common Report Var(align_loops)
f3fdaec4 222Align the start of loops
6ff3a151 223
058de654
NB
224falign-loops=
225Common RejectNegative Joined UInteger
226
31b66477
KC
227; This flag is only tested if alias checking is enabled.
228; 0 if pointer arguments may alias each other. True in C.
229; 1 if pointer arguments may not alias each other but may alias
230; global variables.
231; 2 if pointer arguments may not alias each other and may not
232; alias global variables. True in Fortran.
233; The value is ignored if flag_alias_check is 0.
6ff3a151 234fargument-alias
50431bc4 235Common Report Var(flag_argument_noalias,0)
f3fdaec4 236Specify that arguments may alias each other and globals
6ff3a151
NB
237
238fargument-noalias
50431bc4 239Common Report Var(flag_argument_noalias,1) VarExists
f3fdaec4 240Assume arguments may alias globals but not each other
6ff3a151
NB
241
242fargument-noalias-global
50431bc4 243Common Report Var(flag_argument_noalias,2) VarExists
f3fdaec4 244Assume arguments alias neither each other nor globals
6ff3a151
NB
245
246fasynchronous-unwind-tables
50431bc4 247Common Report Var(flag_asynchronous_unwind_tables)
f3fdaec4 248Generate unwind tables that are exact at each instruction boundary
6ff3a151 249
31b66477
KC
250; -fcheck-bounds causes gcc to generate array bounds checks.
251; For C, C++ and ObjC: defaults off.
252; For Java: defaults to on.
253; For Fortran: defaults to off.
6ff3a151 254fbounds-check
50431bc4 255Common Report Var(flag_bounds_check)
f3fdaec4 256Generate code to check bounds before indexing arrays
6ff3a151
NB
257
258fbranch-count-reg
50431bc4 259Common Report Var(flag_branch_on_count_reg) Init(1)
f3fdaec4 260Replace add, compare, branch with branch on count register
6ff3a151
NB
261
262fbranch-probabilities
50431bc4 263Common Report Var(flag_branch_probabilities)
f3fdaec4 264Use profiling information for branch probabilities
6ff3a151 265
de32c0cb 266fbranch-target-load-optimize
50431bc4 267Common Report Var(flag_branch_target_load_optimize)
f3fdaec4 268Perform branch target load optimization before prologue / epilogue threading
de32c0cb
NB
269
270fbranch-target-load-optimize2
50431bc4 271Common Report Var(flag_branch_target_load_optimize2)
f3fdaec4 272Perform branch target load optimization after prologue / epilogue threading
de32c0cb 273
1194fc79 274fbtr-bb-exclusive
50431bc4 275Common Report Var(flag_btr_bb_exclusive)
1194fc79
R
276Restrict target load migration not to re-use registers in any basic block
277
058de654
NB
278fcall-saved-
279Common Joined RejectNegative
cf03fd63 280-fcall-saved-<register> Mark <register> as being preserved across functions
058de654
NB
281
282fcall-used-
283Common Joined RejectNegative
cf03fd63 284-fcall-used-<register> Mark <register> as being corrupted by function calls
058de654 285
31b66477
KC
286; Nonzero for -fcaller-saves: allocate values in regs that need to
287; be saved across function calls, if that produces overall better code.
288; Optional now, so people can test it.
de32c0cb 289fcaller-saves
50431bc4 290Common Report Var(flag_caller_saves)
f3fdaec4 291Save registers around function calls
de32c0cb 292
6ff3a151 293fcommon
50431bc4 294Common Report Var(flag_no_common,0)
f3fdaec4 295Do not put uninitialized globals in the common section
6ff3a151
NB
296
297fcprop-registers
50431bc4 298Common Report Var(flag_cprop_registers)
f3fdaec4 299Perform a register copy-propagation optimization pass
6ff3a151 300
de32c0cb 301fcrossjumping
50431bc4 302Common Report Var(flag_crossjumping)
f3fdaec4 303Perform cross-jumping optimization
de32c0cb
NB
304
305fcse-follow-jumps
50431bc4 306Common Report Var(flag_cse_follow_jumps)
f3fdaec4 307When running CSE, follow jumps to their targets
de32c0cb
NB
308
309fcse-skip-blocks
50431bc4 310Common Report Var(flag_cse_skip_blocks)
f3fdaec4 311When running CSE, follow conditional jumps
de32c0cb 312
c7463669
RH
313fcx-limited-range
314Common Report Var(flag_cx_limited_range)
315Omit range reduction step when performing complex division
316
6ff3a151 317fdata-sections
50431bc4 318Common Report Var(flag_data_sections)
f3fdaec4 319Place data items into their own section
6ff3a151 320
31b66477
KC
321; Nonzero for -fdefer-pop: don't pop args after each function call
322; instead save them up to pop many calls' args with one insns.
de32c0cb 323fdefer-pop
50431bc4 324Common Report Var(flag_defer_pop)
f3fdaec4 325Defer popping functions args from stack until later
de32c0cb
NB
326
327fdelayed-branch
50431bc4 328Common Report Var(flag_delayed_branch)
f3fdaec4 329Attempt to fill delay slots of branch instructions
de32c0cb
NB
330
331fdelete-null-pointer-checks
50431bc4 332Common Report Var(flag_delete_null_pointer_checks)
f3fdaec4 333Delete useless null pointer checks
de32c0cb
NB
334
335fdiagnostics-show-location=
336Common Joined RejectNegative
cf03fd63 337-fdiagnostics-show-location=[once|every-line] How often to emit source location at the beginning of line-wrapped diagnostics
de32c0cb 338
6de9cd9a
DN
339fdump-
340Common Joined RejectNegative
341-fdump-<type> Dump various compiler internals to a file
342
6ff3a151 343fdump-unnumbered
50431bc4 344Common Report Var(flag_dump_unnumbered) VarExists
f3fdaec4 345Suppress output of instruction numbers and line number notes in debugging dumps
6ff3a151 346
de32c0cb 347feliminate-dwarf2-dups
50431bc4 348Common Report Var(flag_eliminate_dwarf2_dups)
f3fdaec4 349Perform DWARF2 duplicate elimination
de32c0cb 350
6a08f7b3 351feliminate-unused-debug-symbols
50431bc4 352Common Report Var(flag_debug_only_used_symbols)
f3fdaec4 353Perform unused type elimination in debug info
6a08f7b3 354
de32c0cb 355feliminate-unused-debug-types
50431bc4 356Common Report Var(flag_eliminate_unused_debug_types) Init(1)
f3fdaec4 357Perform unused type elimination in debug info
de32c0cb 358
6ff3a151 359fexceptions
50431bc4 360Common Report Var(flag_exceptions)
f3fdaec4 361Enable exception handling
6ff3a151 362
de32c0cb 363fexpensive-optimizations
50431bc4 364Common Report Var(flag_expensive_optimizations)
f3fdaec4 365Perform a number of minor, expensive optimizations
de32c0cb 366
058de654
NB
367ffast-math
368Common
369
6ff3a151 370ffinite-math-only
50431bc4 371Common Report Var(flag_finite_math_only)
f3fdaec4 372Assume no NaNs or infinities are generated
6ff3a151 373
058de654
NB
374ffixed-
375Common Joined RejectNegative
cf03fd63 376-ffixed-<register> Mark <register> as being unavailable to the compiler
058de654 377
de32c0cb 378ffloat-store
50431bc4 379Common Report Var(flag_float_store)
31b66477 380Don't allocate floats and doubles in extended-precision registers
de32c0cb 381
31b66477
KC
382; Nonzero for -fforce-addr: load memory address into a register before
383; reference to memory. This makes better cse but slower compilation.
de32c0cb 384fforce-addr
50431bc4 385Common Report Var(flag_force_addr)
f3fdaec4 386Copy memory address constants into registers before use
de32c0cb 387
31b66477
KC
388; Nonzero for -fforce-mem: load memory value into a register
389; before arithmetic on it. This makes better cse but slower compilation.
de32c0cb 390fforce-mem
50431bc4 391Common Report Var(flag_force_mem)
f3fdaec4 392Copy memory operands into registers before use
de32c0cb 393
31b66477
KC
394; Nonzero means don't put addresses of constant functions in registers.
395; Used for compiling the Unix kernel, where strange substitutions are
396; done on the assembly output.
de32c0cb 397ffunction-cse
50431bc4 398Common Report Var(flag_no_function_cse,0)
f3fdaec4 399Allow function addresses to be held in registers
de32c0cb 400
6ff3a151 401ffunction-sections
50431bc4 402Common Report Var(flag_function_sections)
f3fdaec4 403Place each function into its own section
6ff3a151 404
de32c0cb 405fgcse
50431bc4 406Common Report Var(flag_gcse)
f3fdaec4 407Perform global common subexpression elimination
de32c0cb
NB
408
409fgcse-lm
50431bc4 410Common Report Var(flag_gcse_lm) Init(1)
f3fdaec4 411Perform enhanced load motion during global common subexpression elimination
de32c0cb
NB
412
413fgcse-sm
21ef99b8 414Common Report Var(flag_gcse_sm) Init(0)
f3fdaec4 415Perform store motion after global common subexpression elimination
de32c0cb 416
f5f2e3cd 417fgcse-las
21ef99b8 418Common Report Var(flag_gcse_las) Init(0)
f9957958
MH
419Perform redundant load after store elimination in global common subexpression
420elimination
421
422fgcse-after-reload
50431bc4 423Common Report Var(flag_gcse_after_reload)
f9957958
MH
424Perform global common subexpression elimination after register allocation
425has finished.
f5f2e3cd 426
6ff3a151 427fguess-branch-probability
50431bc4 428Common Report Var(flag_guess_branch_prob)
f3fdaec4 429Enable guessing of branch probabilities
6ff3a151 430
31b66477
KC
431; Nonzero means ignore `#ident' directives. 0 means handle them.
432; Generate position-independent code for executables if possible
433; On SVR4 targets, it also controls whether or not to emit a
434; string identifying the compiler.
6ff3a151 435fident
50431bc4 436Common Report Var(flag_no_ident,0)
f3fdaec4 437Process #ident directives
6ff3a151 438
de32c0cb 439fif-conversion
50431bc4 440Common Report Var(flag_if_conversion)
f3fdaec4 441Perform conversion of conditional jumps to branchless equivalents
de32c0cb
NB
442
443fif-conversion2
50431bc4 444Common Report Var(flag_if_conversion2)
f3fdaec4 445Perform conversion of conditional jumps to conditional execution
de32c0cb 446
31b66477
KC
447; -finhibit-size-directive inhibits output of .size for ELF.
448; This is used only for compiling crtstuff.c,
449; and it may be extended to other effects
450; needed for crtstuff.c on other systems.
6ff3a151 451finhibit-size-directive
50431bc4 452Common Report Var(flag_inhibit_size_directive)
f3fdaec4 453Do not generate .size directives
6ff3a151 454
31b66477
KC
455; Nonzero means that functions declared `inline' will be treated
456; as `static'. Prevents generation of zillions of copies of unused
457; static inline functions; instead, `inlines' are written out
458; only when actually used. Used in conjunction with -g. Also
459; does the right thing with #pragma interface.
de32c0cb 460finline
50431bc4 461Common Report Var(flag_no_inline,0) Init(2)
f3fdaec4 462Pay attention to the \"inline\" keyword
de32c0cb
NB
463
464finline-functions
50431bc4 465Common Report Var(flag_inline_functions)
f3fdaec4 466Integrate simple functions into their callers
de32c0cb 467
d302c9d6
NB
468finline-limit-
469Common RejectNegative Joined UInteger
470
471finline-limit=
472Common RejectNegative Joined UInteger
cf03fd63 473-finline-limit=<number> Limit the size of inlined functions to <number>
d302c9d6 474
6ff3a151 475finstrument-functions
50431bc4 476Common Report Var(flag_instrument_function_entry_exit)
f3fdaec4 477Instrument function entry and exit with profiling calls
6ff3a151 478
8b11a64c
ZD
479fivopts
480Common Report Var(flag_ivopts) Init(1)
481Optimize induction variables on trees
482
de32c0cb 483fkeep-inline-functions
50431bc4 484Common Report Var(flag_keep_inline_functions)
f3fdaec4 485Generate code for functions even if they are fully inlined
de32c0cb
NB
486
487fkeep-static-consts
50431bc4 488Common Report Var(flag_keep_static_consts) Init(1)
f3fdaec4 489Emit static const variables even if they are not used
de32c0cb 490
6ff3a151 491fleading-underscore
50431bc4 492Common Report Var(flag_leading_underscore) Init(-1)
f3fdaec4 493Give external symbols a leading underscore
6ff3a151 494
de32c0cb 495floop-optimize
50431bc4 496Common Report Var(flag_loop_optimize)
f3fdaec4 497Perform loop optimizations
de32c0cb 498
5e962776
ZD
499floop-optimize2
500Common Report Var(flag_loop_optimize2)
501Perform loop optimizations using the new loop optimizer
502
6ff3a151 503fmath-errno
50431bc4 504Common Report Var(flag_errno_math) Init(1)
f3fdaec4 505Set errno after built-in math functions
6ff3a151
NB
506
507fmem-report
50431bc4 508Common Report Var(mem_report)
f3fdaec4 509Report on permanent memory allocation
6ff3a151 510
31b66477
KC
511; This will attempt to merge constant section constants, if 1 only
512; string constants and constants from constant pool, if 2 also constant
513; variables.
6ff3a151 514fmerge-all-constants
50431bc4 515Common Report Var(flag_merge_constants,2) Init(1)
f3fdaec4 516Attempt to merge identical constants and constant variables
6ff3a151
NB
517
518fmerge-constants
50431bc4 519Common Report Var(flag_merge_constants,1) VarExists
f3fdaec4 520Attempt to merge identical constants across compilation units
6ff3a151 521
de32c0cb
NB
522fmessage-length=
523Common RejectNegative Joined UInteger
cf03fd63 524-fmessage-length=<number> Limit diagnostics to <number> characters per line. 0 suppresses line-wrapping
de32c0cb 525
e5626198 526fmodulo-sched
50431bc4 527Common Report Var(flag_modulo_sched)
e5626198
AZ
528Perform SMS based modulo scheduling before the first scheduling pass
529
5e962776
ZD
530fmove-loop-invariants
531Common Report Var(flag_move_loop_invariants)
532Move loop invariant computations out of loops
533
6de9cd9a 534fmudflap
50431bc4 535Common RejectNegative Report Var(flag_mudflap)
6de9cd9a
DN
536Add mudflap bounds-checking instrumentation for single-threaded program.
537
538fmudflapth
50431bc4 539Common RejectNegative Report Var(flag_mudflap_threads)
6de9cd9a
DN
540Add mudflap bounds-checking instrumentation for multi-threaded program.
541
542fmudflapir
50431bc4 543Common RejectNegative Report Var(flag_mudflap_ignore_reads)
6de9cd9a
DN
544Ignore read operations when inserting mudflap instrumentation.
545
d72372e4
MH
546freschedule-modulo-scheduled-loops
547Common Report Var(flag_resched_modulo_sched)
548Enable/Disable the traditional scheduling in loops that already passed modulo scheduling
549
6ff3a151 550fnon-call-exceptions
50431bc4 551Common Report Var(flag_non_call_exceptions)
f3fdaec4 552Support synchronous non-call exceptions
6ff3a151 553
de32c0cb 554fomit-frame-pointer
50431bc4 555Common Report Var(flag_omit_frame_pointer)
f3fdaec4 556When possible do not generate stack frames
de32c0cb 557
6ff3a151 558foptimize-register-move
50431bc4 559Common Report Var(flag_regmove)
f3fdaec4 560Do the full register move optimization pass
6ff3a151 561
de32c0cb 562foptimize-sibling-calls
50431bc4 563Common Report Var(flag_optimize_sibling_calls)
f3fdaec4 564Optimize sibling and tail recursive calls
de32c0cb 565
6ff3a151 566fpack-struct
50431bc4 567Common Report Var(flag_pack_struct)
f3fdaec4 568Pack structure members together without holes
6ff3a151 569
467cecf3
JB
570fpack-struct=
571Common RejectNegative Joined UInteger
572-fpack-struct=<number> Set initial maximum structure member alignment
573
de32c0cb 574fpcc-struct-return
50431bc4 575Common Report Var(flag_pcc_struct_return,1) VarExists
f3fdaec4 576Return small aggregates in memory, not registers
de32c0cb
NB
577
578fpeel-loops
50431bc4 579Common Report Var(flag_peel_loops)
f3fdaec4 580Perform loop peeling
de32c0cb
NB
581
582fpeephole
50431bc4 583Common Report Var(flag_no_peephole,0)
f3fdaec4 584Enable machine specific peephole optimizations
de32c0cb 585
6ff3a151 586fpeephole2
50431bc4 587Common Report Var(flag_peephole2)
f3fdaec4 588Enable an RTL peephole pass before sched2
6ff3a151 589
31b66477
KC
590fPIC
591Common Report Var(flag_pic,2)
592Generate position-independent code if possible (large mode)
593
594fPIE
595Common Report Var(flag_pie,2)
596Generate position-independent code for executables if possible (large mode)
597
6ff3a151 598fpic
50431bc4 599Common Report Var(flag_pic,1) VarExists
31b66477 600Generate position-independent code if possible (small mode)
6ff3a151
NB
601
602fpie
50431bc4 603Common Report Var(flag_pie,1) VarExists
31b66477 604Generate position-independent code for executables if possible (small mode)
6ff3a151 605
de32c0cb 606fprefetch-loop-arrays
50431bc4 607Common Report Var(flag_prefetch_loop_arrays)
f3fdaec4 608Generate prefetch instructions, if available, for arrays in loops
de32c0cb 609
6ff3a151 610fprofile
50431bc4 611Common Report Var(profile_flag)
f3fdaec4 612Enable basic program profiling code
6ff3a151
NB
613
614fprofile-arcs
50431bc4 615Common Report Var(profile_arc_flag)
f3fdaec4 616Insert arc-based program profiling code
6ff3a151 617
a8a5f53a
JH
618fprofile-generate
619Common
620Enable common options for generating profile info for profile feedback directed optimizations
621
622fprofile-use
623Common
624Enable common options for performing profile feedback directed optimizations
625
fca9dc00 626fprofile-values
50431bc4 627Common Report Var(flag_profile_values)
fca9dc00
ZD
628Insert code to profile values of expressions
629
de32c0cb
NB
630frandom-seed
631Common
632
633frandom-seed=
634Common Joined RejectNegative
cf03fd63 635-frandom-seed=<string> Make compile reproducible using <string>
de32c0cb 636
de32c0cb 637freg-struct-return
50431bc4 638Common Report Var(flag_pcc_struct_return,0) VarExists
f3fdaec4 639Return small aggregates in registers
de32c0cb 640
6ff3a151 641fregmove
50431bc4 642Common Report Var(flag_regmove)
f3fdaec4 643Enables a register move optimization
6ff3a151
NB
644
645frename-registers
50431bc4 646Common Report Var(flag_rename_registers)
f3fdaec4 647Perform a register renaming optimization pass
6ff3a151
NB
648
649freorder-blocks
50431bc4 650Common Report Var(flag_reorder_blocks)
f3fdaec4 651Reorder basic blocks to improve code placement
6ff3a151 652
750054a2 653freorder-blocks-and-partition
50431bc4 654Common Report Var(flag_reorder_blocks_and_partition)
750054a2
CT
655Reorder basic blocks and partition into hot and cold sections
656
6ff3a151 657freorder-functions
50431bc4 658Common Report Var(flag_reorder_functions)
f3fdaec4 659Reorder functions to improve code placement
6ff3a151 660
de32c0cb 661frerun-cse-after-loop
50431bc4 662Common Report Var(flag_rerun_cse_after_loop)
f3fdaec4 663Add a common subexpression elimination pass after loop optimizations
de32c0cb
NB
664
665frerun-loop-opt
50431bc4 666Common Report Var(flag_rerun_loop_opt)
f3fdaec4 667Run the loop optimizer twice
de32c0cb 668
039c3d42 669frounding-math
50431bc4 670Common Report Var(flag_rounding_math)
039c3d42
RS
671Disable optimizations that assume default FP rounding behavior
672
6ff3a151 673fsched-interblock
50431bc4 674Common Report Var(flag_schedule_interblock) Init(1)
f3fdaec4 675Enable scheduling across basic blocks
6ff3a151
NB
676
677fsched-spec
50431bc4 678Common Report Var(flag_schedule_speculative) Init(1)
f3fdaec4 679Allow speculative motion of non-loads
6ff3a151
NB
680
681fsched-spec-load
50431bc4 682Common Report Var(flag_schedule_speculative_load)
f3fdaec4 683Allow speculative motion of some loads
6ff3a151
NB
684
685fsched-spec-load-dangerous
50431bc4 686Common Report Var(flag_schedule_speculative_load_dangerous)
f3fdaec4 687Allow speculative motion of more loads
6ff3a151 688
de32c0cb
NB
689fsched-verbose=
690Common RejectNegative Joined
cf03fd63 691-fsched-verbose=<number> Set the verbosity level of the scheduler
de32c0cb 692
6ff3a151 693fsched2-use-superblocks
50431bc4 694Common Report Var(flag_sched2_use_superblocks)
f3fdaec4 695If scheduling post reload, do superblock scheduling
6ff3a151
NB
696
697fsched2-use-traces
50431bc4 698Common Report Var(flag_sched2_use_traces)
f3fdaec4 699If scheduling post reload, do trace scheduling
6ff3a151 700
de32c0cb 701fschedule-insns
50431bc4 702Common Report Var(flag_schedule_insns)
f3fdaec4 703Reschedule instructions before register allocation
de32c0cb
NB
704
705fschedule-insns2
50431bc4 706Common Report Var(flag_schedule_insns_after_reload)
f3fdaec4 707Reschedule instructions after register allocation
de32c0cb 708
31b66477
KC
709; sched_stalled_insns means that insns can be moved prematurely from the queue
710; of stalled insns into the ready list.
569fa502 711fsched-stalled-insns
50431bc4 712Common Report Var(flag_sched_stalled_insns)
569fa502
DN
713Allow premature scheduling of queued insns
714
715fsched-stalled-insns=
716Common RejectNegative Joined UInteger
717-fsched-stalled-insns=<number> Set number of queued insns that can be prematurely scheduled
718
31b66477
KC
719; sched_stalled_insns_dep controls how many recently scheduled cycles will
720; be examined for a dependency on a stalled insn that is candidate for
721; premature removal from the queue of stalled insns into the ready list (has
722; an effect only if the flag 'sched_stalled_insns' is set).
569fa502 723fsched-stalled-insns-dep
50431bc4 724Common Report Var(flag_sched_stalled_insns_dep,1) Init(1)
569fa502
DN
725Set dependence distance checking in premature scheduling of queued insns
726
727fsched-stalled-insns-dep=
728Common RejectNegative Joined UInteger
729-fsched-stalled-insns-dep=<number> Set dependence distance checking in premature scheduling of queued insns
730
de32c0cb 731fshared-data
50431bc4 732Common Report Var(flag_shared_data)
f3fdaec4 733Mark data as shared rather than private
de32c0cb 734
6ff3a151 735fsignaling-nans
50431bc4 736Common Report Var(flag_signaling_nans)
f3fdaec4 737Disable optimizations observable by IEEE signaling NaNs
6ff3a151
NB
738
739fsingle-precision-constant
50431bc4 740Common Report Var(flag_single_precision_constant)
f3fdaec4 741Convert floating point constants to single precision constants
6ff3a151 742
6d9901e7
ZD
743fspeculative-prefetching
744Common Report Var(flag_speculative_prefetching)
745Use value profiling for speculative prefetching
746
113d659a
ZD
747fsplit-ivs-in-unroller
748Common Report Var(flag_split_ivs_in_unroller) Init(1)
749Split lifetimes of induction variables when loops are unrolled.
750
f37a4f14
RE
751fvariable-expansion-in-unroller
752Common Report Var(flag_variable_expansion_in_unroller)
753Apply variable expansion when loops are unrolled.
754
31b66477
KC
755; Emit code to probe the stack, to help detect stack overflow; also
756; may cause large objects to be allocated dynamically.
6ff3a151 757fstack-check
50431bc4 758Common Report Var(flag_stack_check)
f3fdaec4 759Insert stack checking code into the program
6ff3a151 760
de32c0cb
NB
761fstack-limit
762Common
763
058de654
NB
764fstack-limit-register=
765Common RejectNegative Joined
cf03fd63 766-fstack-limit-register=<register> Trap if the stack goes past <register>
058de654
NB
767
768fstack-limit-symbol=
769Common RejectNegative Joined
cf03fd63 770-fstack-limit-symbol=<name> Trap if the stack goes past symbol <name>
058de654 771
de32c0cb 772fstrength-reduce
50431bc4 773Common Report Var(flag_strength_reduce)
f3fdaec4 774Perform strength reduction optimizations
de32c0cb 775
31b66477
KC
776; Nonzero if we should do (language-dependent) alias analysis.
777; Typically, this analysis will assume that expressions of certain
778; types do not alias expressions of certain other types. Only used
779; if alias analysis (in general) is enabled.
6ff3a151 780fstrict-aliasing
50431bc4 781Common Report Var(flag_strict_aliasing)
f3fdaec4 782Assume strict aliasing rules apply
6ff3a151 783
de32c0cb 784fsyntax-only
50431bc4 785Common Report Var(flag_syntax_only)
f3fdaec4 786Check for syntax errors, then stop
de32c0cb 787
6ff3a151 788ftest-coverage
50431bc4 789Common Report Var(flag_test_coverage)
f3fdaec4 790Create data files needed by \"gcov\"
6ff3a151 791
de32c0cb 792fthread-jumps
50431bc4 793Common Report Var(flag_thread_jumps)
f3fdaec4 794Perform jump threading optimizations
de32c0cb 795
6ff3a151 796ftime-report
50431bc4 797Common Report Var(time_report)
f3fdaec4 798Report the time taken by each compiler pass
6ff3a151 799
058de654
NB
800ftls-model=
801Common Joined RejectNegative
cf03fd63 802-ftls-model=[global-dynamic|local-dynamic|initial-exec|local-exec] Set the default thread-local storage code generation model
058de654 803
de32c0cb 804ftracer
50431bc4 805Common Report Var(flag_tracer)
f3fdaec4 806Perform superblock formation via tail duplication
de32c0cb 807
31b66477
KC
808; Zero means that floating-point math operations cannot generate a
809; (user-visible) trap. This is the case, for example, in nonstop
810; IEEE 754 arithmetic.
6ff3a151 811ftrapping-math
10060b83 812Common Report Var(flag_trapping_math) Init(1)
f3fdaec4 813Assume floating-point operations can trap
6ff3a151
NB
814
815ftrapv
50431bc4 816Common Report Var(flag_trapv)
f3fdaec4 817Trap for signed overflow in addition, subtraction and multiplication
6ff3a151 818
6de9cd9a 819ftree-based-profiling
50431bc4 820Common Report Var(flag_tree_based_profiling)
6de9cd9a
DN
821Use tree-ssa based implementation of profiling
822
823ftree-ccp
50431bc4 824Common Report Var(flag_tree_ccp)
6de9cd9a
DN
825Enable SSA-CCP optimization on trees
826
827ftree-ch
50431bc4 828Common Report Var(flag_tree_ch)
6de9cd9a
DN
829Enable loop header copying on trees
830
831ftree-combine-temps
50431bc4 832Common Report Var(flag_tree_combine_temps)
6de9cd9a
DN
833Coalesce memory temporaries in the SSA->normal pass
834
835ftree-copyrename
50431bc4 836Common Report Var(flag_tree_copyrename)
6de9cd9a
DN
837Replace SSA temporaries with better names in copies.
838
839ftree-dce
50431bc4 840Common Report Var(flag_tree_dce)
6de9cd9a
DN
841Enable SSA dead code elimination optimization on trees
842
843ftree-dominator-opts
50431bc4 844Common Report Var(flag_tree_dom)
6de9cd9a
DN
845Enable dominator optimizations
846
847ftree-dse
50431bc4 848Common Report Var(flag_tree_dse)
6de9cd9a
DN
849Enable dead store elimination
850
ff2ad0f7
DN
851ftree-fre
852Common Report Var(flag_tree_fre)
853Enable Full Redundancy Elimination (FRE) on trees
854
1b08d87d
DB
855ftree-loop-im
856Common Report Var(flag_tree_loop_im) Init(1)
a7e5372d
ZD
857Enable loop invariant motion on trees
858
599eabdb
DB
859ftree-loop-linear
860Common Report Var(flag_tree_loop_linear)
861Enable linear loop transforms on trees
862
1b08d87d 863ftree-loop-ivcanon
47bcd07d 864Common Report Var(flag_tree_loop_ivcanon) Init(1)
1b08d87d
DB
865Create canonical induction variables in loops
866
c66b6c66
ZD
867ftree-loop-optimize
868Common Report Var(flag_tree_loop_optimize) Init(1)
869Enable loop optimizations on tree level
870
6de9cd9a 871ftree-pre
50431bc4 872Common Report Var(flag_tree_pre)
6de9cd9a
DN
873Enable SSA-PRE optimization on trees
874
c75ab022
DB
875ftree-salias
876Common Report Var(flag_tree_salias)
877Perform structural alias analysis
878
fa555252
DB
879ftree-sink
880Common Report Var(flag_tree_sink)
881Enable SSA code sinking on trees
882
6de9cd9a 883ftree-sra
50431bc4 884Common Report Var(flag_tree_sra)
6de9cd9a
DN
885Perform scalar replacement of aggregates
886
887ftree-ter
50431bc4 888Common Report Var(flag_tree_ter)
6de9cd9a
DN
889Replace temporary expressions in the SSA->normal pass
890
891ftree-lrs
50431bc4 892Common Report Var(flag_tree_live_range_split)
6de9cd9a
DN
893Perform live range splitting during the SSA->normal pass.
894
de32c0cb 895funit-at-a-time
50431bc4 896Common Report Var(flag_unit_at_a_time)
f3fdaec4 897Compile whole compilation unit at a time
de32c0cb
NB
898
899funroll-loops
50431bc4 900Common Report Var(flag_unroll_loops)
f3fdaec4 901Perform loop unrolling when iteration count is known
de32c0cb
NB
902
903funroll-all-loops
50431bc4 904Common Report Var(flag_unroll_all_loops)
f3fdaec4 905Perform loop unrolling for all loops
de32c0cb 906
31b66477
KC
907; Nonzero means that unsafe floating-point math optimizations are allowed
908; for the sake of speed. IEEE compliance is not guaranteed, and operations
909; are allowed to assume that their arguments and results are "normal"
910; (e.g., nonnegative for SQRT).
6ff3a151 911funsafe-math-optimizations
50431bc4 912Common Report Var(flag_unsafe_math_optimizations)
f3fdaec4 913Allow math optimizations that may violate IEEE or ISO standards
6ff3a151 914
de32c0cb 915funswitch-loops
50431bc4 916Common Report Var(flag_unswitch_loops)
f3fdaec4 917Perform loop unswitching
de32c0cb 918
6ff3a151 919funwind-tables
50431bc4 920Common Report Var(flag_unwind_tables)
f3fdaec4 921Just generate unwind tables for exception handling
6ff3a151 922
014a1138 923fvar-tracking
50431bc4 924Common Report Var(flag_var_tracking) VarExists
014a1138
JZ
925Perform variable tracking
926
79fe1b3b
DN
927ftree-vectorize
928Common Report Var(flag_tree_vectorize)
929Enable loop vectorization on trees
930
c866976a
LB
931ftree-vectorizer-verbose=
932Common RejectNegative Joined
933-ftree-vectorizer-verbose=<number> Set the verbosity level of the vectorizer
934
31b66477
KC
935; -fverbose-asm causes extra commentary information to be produced in
936; the generated assembly code (to make it more readable). This option
937; is generally only of use to those who actually need to read the
938; generated assembly code (perhaps while debugging the compiler itself).
939; -fno-verbose-asm, the default, causes the extra information
940; to not be added and is useful when comparing two assembler files.
6ff3a151 941fverbose-asm
50431bc4 942Common Report Var(flag_verbose_asm)
f3fdaec4 943Add extra commentary to assembler output
6ff3a151 944
d7afec4b
ND
945fvisibility=
946Common Joined RejectNegative
947-fvisibility=[default|internal|hidden|protected] Set the default symbol visibility
948
949
fca9dc00 950fvpt
50431bc4 951Common Report Var(flag_value_profile_transformations)
fca9dc00
ZD
952Use expression value profiles in optimizations
953
62551c66 954fweb
21ef99b8 955Common Report Var(flag_web) Init(0)
62551c66
JH
956Construct webs and split unrelated uses of single variable
957
6ff3a151 958fwrapv
50431bc4 959Common Report Var(flag_wrapv)
f3fdaec4 960Assume signed arithmetic overflow wraps around
6ff3a151 961
6ff3a151 962fzero-initialized-in-bss
50431bc4 963Common Report Var(flag_zero_initialized_in_bss) Init(1)
f3fdaec4 964Put zero initialized data in the bss section
6ff3a151 965
e01cc6dc
NB
966g
967Common JoinedOrMissing
df38ffef
NB
968Generate debug information in default format
969
970gcoff
971Common JoinedOrMissing
972Generate debug information in COFF format
973
df38ffef
NB
974gdwarf-2
975Common JoinedOrMissing
976Generate debug information in DWARF v2 format
977
978ggdb
979Common JoinedOrMissing
980Generate debug information in default extended format
981
982gstabs
983Common JoinedOrMissing
984Generate debug information in STABS format
985
986gstabs+
987Common JoinedOrMissing
988Generate debug information in extended STABS format
989
990gvms
991Common JoinedOrMissing
992Generate debug information in VMS format
993
994gxcoff
995Common JoinedOrMissing
996Generate debug information in XCOFF format
997
998gxcoff+
999Common JoinedOrMissing
1000Generate debug information in extended XCOFF format
e01cc6dc 1001
d185d268
NB
1002o
1003Common Joined Separate
cf03fd63 1004-o <file> Place output into <file>
d185d268
NB
1005
1006p
50431bc4 1007Common Var(profile_flag)
cf03fd63 1008Enable function profiling
d185d268
NB
1009
1010pedantic
50431bc4 1011Common Var(pedantic)
cf03fd63 1012Issue warnings needed for strict compliance to the standard
d185d268
NB
1013
1014pedantic-errors
1015Common
cf03fd63 1016Like -pedantic but issue them as errors
d185d268 1017
d7b42618 1018quiet
50431bc4 1019Common Var(quiet_flag)
cf03fd63 1020Do not display functions compiled or elapsed time
d7b42618 1021
d185d268 1022version
50431bc4 1023Common Var(version_flag)
cf03fd63 1024Display the compiler's version
d185d268
NB
1025
1026w
50431bc4 1027Common Var(inhibit_warnings)
cf03fd63 1028Suppress warnings
d185d268 1029
d7b42618 1030; This comment is to ensure we retain the blank line above.
This page took 0.71312 seconds and 5 git commands to generate.