tree.h (PHI_CHAIN): New.
[gcc.git] / gcc / c.opt
1 ; Options for the C, ObjC, C++ and ObjC++ front ends.
2 ; Copyright (C) 2003, 2004 Free Software Foundation, Inc.
3 ;
4 ; This file is part of GCC.
5 ;
6 ; GCC is free software; you can redistribute it and/or modify it under
7 ; the terms of the GNU General Public License as published by the Free
8 ; Software Foundation; either version 2, or (at your option) any later
9 ; version.
10 ;
11 ; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
12 ; WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 ; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 ; for more details.
15 ;
16 ; You should have received a copy of the GNU General Public License
17 ; along with GCC; see the file COPYING. If not, write to the Free
18 ; Software Foundation, 59 Temple Place - Suite 330, Boston, MA
19 ; 02111-1307, USA.
20
21
22 ; This file is processed by the script opts.sh. It is a database of
23 ; command line options, with each record separated by a blank line,
24 ; and each field appearing on its own line. The first field is the
25 ; command-line switch with the leading "-" removed. All options
26 ; beginning with "f" or "W" are implicitly assumed to take a "no-"
27 ; form; this form should not be listed. If you do not want this
28 ; negative form and you want it to be automatically rejected, add
29 ; RejectNegative to the second field.
30
31 ; The second field is a space-separated list of which parts of the
32 ; compiler recognize the switch, as declared by "Language" entries.
33 ; If the switch takes an argument, then you should also specify
34 ; "Joined" and/or "Separate" to indicate where the argument can
35 ; appear. If a Joined argument can legitimately be omitted, specify
36 ; "JoinedOrMissing" instead of "Joined". If the argument to a switch
37 ; is a non-negative integer, you can specify "UInteger" and the switch
38 ; decoder will convert the argument for you, or complain to the user
39 ; if the argument is invalid. "Var(name,set)" creates an integer
40 ; variable "name". The variable is declared and initialized to value
41 ; given by "Init(value)" (or zero if this property is not defined).
42 ; When the option is passed to compiler, this variable is set to "set"
43 ; if value passed through the flag is nonzero, !"set" if value is zero,
44 ; or to value if "set" is omitted. If "VarExists" is specified, the
45 ; declaration for the variable is not created. If "Report" is specified,
46 ; the flag is output with -fverbose-asm.
47
48 ; The third field is the help text to output with --help. This is
49 ; automatically line-wrapped on output. Normally the switch is output
50 ; automatically, with the help text on the right hand side of the
51 ; output. However, if the help text contains a tab character, the
52 ; text to the left of the tab is output instead of the switch, and the
53 ; text to its right forms the help. This is useful for elaborating on
54 ; what type of argument a switch takes, for example. If the second
55 ; field contains "Undocumented" then nothing is output with --help.
56 ; Only do this with good reason like the switch being internal between
57 ; the driver and the front end - it is not an excuse to leave a switch
58 ; undocumented.
59
60 ; Comments can appear on their own line anwhere in the file, preceded
61 ; by a semicolon. Whitespace is permitted before the semicolon.
62
63 ; For each switch XXX below, an enumeration constant is created by the
64 ; script opts.sh spelt OPT_XXX, but with all non-alphanumeric
65 ; characters replaced with an underscore.
66
67 ; Please try to keep this file in ASCII collating order.
68
69 Language
70 C
71
72 Language
73 ObjC
74
75 Language
76 C++
77
78 Language
79 ObjC++
80
81 -output-pch=
82 C ObjC C++ ObjC++ Joined Separate
83
84 A
85 C ObjC C++ ObjC++ Joined Separate
86 -A<question>=<answer> Assert the <answer> to <question>. Putting '-' before <question> disables the <answer> to <question>
87
88 C
89 C ObjC C++ ObjC++
90 Do not discard comments
91
92 CC
93 C ObjC C++ ObjC++
94 Do not discard comments in macro expansions
95
96 D
97 C ObjC C++ ObjC++ Joined Separate
98 -D<macro>[=<val>] Define a <macro> with <val> as its value. If just <macro> is given, <val> is taken to be 1
99
100 E
101 C ObjC C++ ObjC++ Undocumented
102
103 F
104 C ObjC C++ ObjC++ Joined Separate
105 -F <dir> Add <dir> to the end of the main framework include path
106
107 H
108 C ObjC C++ ObjC++
109 Print the name of header files as they are used
110
111 I
112 C ObjC C++ ObjC++ Joined Separate
113 -I <dir> Add <dir> to the end of the main include path
114
115 M
116 C ObjC C++ ObjC++
117 Generate make dependencies
118
119 MD
120 C ObjC C++ ObjC++ Separate
121 Generate make dependencies and compile
122
123 MF
124 C ObjC C++ ObjC++ Joined Separate
125 -MF <file> Write dependency output to the given file
126
127 MG
128 C ObjC C++ ObjC++
129 Treat missing header files as generated files
130
131 MM
132 C ObjC C++ ObjC++
133 Like -M but ignore system header files
134
135 MMD
136 C ObjC C++ ObjC++ Separate
137 Like -MD but ignore system header files
138
139 MP
140 C ObjC C++ ObjC++
141 Generate phony targets for all headers
142
143 MQ
144 C ObjC C++ ObjC++ Joined Separate
145 -MQ <target> Add a MAKE-quoted target
146
147 MT
148 C ObjC C++ ObjC++ Joined Separate
149 -MT <target> Add an unquoted target
150
151 P
152 C ObjC C++ ObjC++
153 Do not generate #line directives
154
155 U
156 C ObjC C++ ObjC++ Joined Separate
157 -U<macro> Undefine <macro>
158
159 Wabi
160 C++ ObjC++
161
162 Wall
163 C ObjC C++ ObjC++
164 Enable most warning messages
165
166 Wbad-function-cast
167 C ObjC
168 Warn about casting functions to incompatible types
169
170 Wcast-qual
171 C ObjC C++ ObjC++
172 Warn about casts which discard qualifiers
173
174 Wchar-subscripts
175 C ObjC C++ ObjC++
176 Warn about subscripts whose type is \"char\"
177
178 Wcomment
179 C ObjC C++ ObjC++
180 Warn about possibly nested block comments, and C++ comments spanning more than one physical line
181
182 Wcomments
183 C ObjC C++ ObjC++
184 Synonym for -Wcomment
185
186 Wconversion
187 C ObjC C++ ObjC++
188 Warn about possibly confusing type conversions
189
190 Wctor-dtor-privacy
191 C++ ObjC++
192 Warn when all constructors and destructors are private
193
194 Wdeclaration-after-statement
195 C ObjC
196 Warn when a declaration is found after a statement
197
198 Wdeprecated
199 C++ ObjC++
200 Warn about deprecated compiler features
201
202 Wdiv-by-zero
203 C ObjC
204 Warn about compile-time integer division by zero
205
206 Weffc++
207 C++ ObjC++
208 Warn about violations of Effective C++ style rules
209
210 Wendif-labels
211 C ObjC C++ ObjC++
212 Warn about stray tokens after #elif and #endif
213
214 Werror
215 C ObjC C++ ObjC++
216 ; Documented in common.opt
217
218 Werror-implicit-function-declaration
219 C ObjC RejectNegative
220 Make implicit function declarations an error
221
222 Wfloat-equal
223 C ObjC C++ ObjC++
224 Warn if testing floating point numbers for equality
225
226 Wformat
227 C ObjC C++ ObjC++
228 Warn about printf/scanf/strftime/strfmon format string anomalies
229
230 Wformat-extra-args
231 C ObjC C++ ObjC++
232 Warn if passing too many arguments to a function for its format string
233
234 Wformat-nonliteral
235 C ObjC C++ ObjC++
236 Warn about format strings that are not literals
237
238 Wformat-security
239 C ObjC C++ ObjC++
240 Warn about possible security problems with format functions
241
242 Wformat-y2k
243 C ObjC C++ ObjC++
244 Warn about strftime formats yielding 2-digit years
245
246 Wformat-zero-length
247 C ObjC
248
249 Wformat=
250 C ObjC C++ ObjC++ Joined
251
252 Winit-self
253 C ObjC C++ ObjC++
254 Warn about variables which are initialized to themselves.
255
256 Wimplicit
257 C ObjC C++ ObjC++
258
259 Wimplicit-function-declaration
260 C ObjC
261 Warn about implicit function declarations
262
263 Wimplicit-int
264 C ObjC
265 Warn when a declaration does not specify a type
266
267 Wimport
268 C ObjC C++ ObjC++
269 Deprecated. This switch has no effect.
270
271 Winvalid-offsetof
272 C++ ObjC++
273 Warn about invalid uses of the \"offsetof\" macro
274
275 Winvalid-pch
276 C ObjC C++ ObjC++
277 Warn about PCH files that are found but not used
278
279 Wlong-long
280 C ObjC C++ ObjC++
281 Do not warn about using \"long long\" when -pedantic
282
283 Wmain
284 C ObjC
285 Warn about suspicious declarations of \"main\"
286
287 Wmissing-braces
288 C ObjC C++ ObjC++
289 Warn about possibly missing braces around initializers
290
291 Wmissing-declarations
292 C ObjC
293 Warn about global functions without previous declarations
294
295 Wmissing-format-attribute
296 C ObjC C++ ObjC++
297 Warn about functions which might be candidates for format attributes
298
299 Wmissing-include-dirs
300 C ObjC C++ ObjC++
301 Warn about user-specified include directories that do not exist
302
303 Wmissing-prototypes
304 C ObjC
305 Warn about global functions without prototypes
306
307 Wmultichar
308 C ObjC C++ ObjC++
309 Warn about use of multi-character character constants
310
311 Wnested-externs
312 C ObjC
313 Warn about \"extern\" declarations not at file scope
314
315 Wnon-template-friend
316 C++ ObjC++
317 Warn when non-templatized friend functions are declared within a template
318
319 Wnon-virtual-dtor
320 C++ ObjC++
321 Warn about non-virtual destructors
322
323 Wnonnull
324 C ObjC
325
326 Wold-style-cast
327 C++ ObjC++
328 Warn if a C-style cast is used in a program
329
330 Wold-style-definition
331 C ObjC
332 Warn if an old-style parameter definition is used
333
334 Woverloaded-virtual
335 C++ ObjC++
336 Warn about overloaded virtual function names
337
338 Wparentheses
339 C ObjC C++ ObjC++
340 Warn about possibly missing parentheses
341
342 Wpmf-conversions
343 C++ ObjC++
344 Warn when converting the type of pointers to member functions
345
346 Wpointer-arith
347 C ObjC C++ ObjC++
348 Warn about function pointer arithmetic
349
350 Wprotocol
351 ObjC ObjC++
352 Warn if inherited methods are unimplemented
353
354 Wredundant-decls
355 C ObjC C++ ObjC++
356 Warn about multiple declarations of the same object
357
358 Wreorder
359 C++ ObjC++
360 Warn when the compiler reorders code
361
362 Wreturn-type
363 C ObjC C++ ObjC++
364 Warn whenever a function's return type defaults to \"int\" (C), or about inconsistent return types (C++)
365
366 Wselector
367 ObjC ObjC++
368 Warn if a selector has multiple methods
369
370 Wsequence-point
371 C ObjC
372 Warn about possible violations of sequence point rules
373
374 Wsign-compare
375 C ObjC C++ ObjC++
376 Warn about signed-unsigned comparisons
377
378 Wsign-promo
379 C++ ObjC++
380 Warn when overload promotes from unsigned to signed
381
382 Wstrict-prototypes
383 C ObjC
384 Warn about unprototyped function declarations
385
386 Wsynth
387 C++ ObjC++
388 Warn when synthesis behavior differs from Cfront
389
390 Wsystem-headers
391 C ObjC C++ ObjC++
392 Do not suppress warnings from system headers
393
394 Wtraditional
395 C ObjC
396 Warn about features not present in traditional C
397
398 Wtrigraphs
399 C ObjC C++ ObjC++
400 Warn if trigraphs are encountered that might affect the meaning of the program
401
402 Wundeclared-selector
403 ObjC ObjC++
404
405 Wundef
406 C ObjC C++ ObjC++
407 Warn if an undefined macro is used in an #if directive
408
409 Wunknown-pragmas
410 C ObjC C++ ObjC++
411 Warn about unrecognized pragmas
412
413 Wunused-macros
414 C ObjC C++ ObjC++
415 Warn about macros defined in the main file that are not used
416
417 Wvariadic-macros
418 C ObjC C++ ObjC++
419 Do not warn about using variadic macros when -pedantic
420
421 Wwrite-strings
422 C ObjC C++ ObjC++
423 Give strings the type \"array of char\"
424
425 ansi
426 C ObjC C++ ObjC++
427 A synonym for -std=c89. In a future version of GCC it will become synonymous with -std=c99 instead
428
429 d
430 C ObjC C++ ObjC++ Joined
431 ; Documented in common.opt. FIXME - what about -dI, -dD, -dN and -dD?
432
433 faccess-control
434 C++ ObjC++
435 Enforce class member access control semantics
436
437 fall-virtual
438 C++ ObjC++
439
440 falt-external-templates
441 C++ ObjC++
442 Change when template instances are emitted
443
444 fasm
445 C ObjC C++ ObjC++
446 Recognize the \"asm\" keyword
447
448 fbuiltin
449 C ObjC C++ ObjC++
450 Recognize built-in functions
451
452 fbuiltin-
453 C ObjC C++ ObjC++ Joined
454
455 fcheck-new
456 C++ ObjC++
457 Check the return value of new
458
459 fcond-mismatch
460 C ObjC C++ ObjC++
461 Allow the arguments of the '?' operator to have different types
462
463 fconserve-space
464 C++ ObjC++
465 Reduce the size of object files
466
467 fconst-strings
468 C++ ObjC++
469 Make string literals \"const char[]\" not \"char[]\"
470
471 fconstant-string-class=
472 ObjC ObjC++ Joined
473 -fconst-string-class=<name> Use class <name> for constant strings
474
475 fdefault-inline
476 C++ ObjC++
477 Inline member functions by default
478
479 fdollars-in-identifiers
480 C ObjC C++ ObjC++
481 Permit '$' as an identifier character
482
483 felide-constructors
484 C++ ObjC++
485
486 fenforce-eh-specs
487 C++ ObjC++
488 Generate code to check exception specifications
489
490 fenum-int-equiv
491 C++ ObjC++
492
493 fexec-charset=
494 C ObjC C++ ObjC++ Joined RejectNegative
495 -fexec-charset=<cset> Convert all strings and character constants to character set <cset>
496
497 finput-charset=
498 C ObjC C++ ObjC++ Joined RejectNegative
499 -finput-charset=<cset> Specify the default character set for source files.
500
501
502 fexternal-templates
503 C++ ObjC++
504
505 ffixed-form
506 C ObjC
507
508 ffixed-line-length-
509 C ObjC Joined
510
511 ffor-scope
512 C++ ObjC++
513 Scope of for-init-statement variables is local to the loop
514
515 ffreestanding
516 C ObjC
517 Do not assume that standard C libraries and \"main\" exist
518
519 fgnu-keywords
520 C++ ObjC++
521 Recognize GNU-defined keywords
522
523 fgnu-runtime
524 ObjC ObjC++
525 Generate code for GNU runtime environment
526
527 fguiding-decls
528 C++ ObjC++
529
530 fhandle-exceptions
531 C++ ObjC++
532
533 fhonor-std
534 C++ ObjC++
535
536 fhosted
537 C ObjC
538 Assume normal C execution environment
539
540 fhuge-objects
541 C++ ObjC++
542 Enable support for huge objects
543
544 fimplement-inlines
545 C++ ObjC++
546 Export functions even if they can be inlined
547
548 fimplicit-inline-templates
549 C++ ObjC++
550 Emit implicit instantiations of inline templates
551
552 fimplicit-templates
553 C++ ObjC++
554 Emit implicit instantiations of templates
555
556 flabels-ok
557 C++ ObjC++
558
559 fms-extensions
560 C ObjC C++ ObjC++
561 Don't warn about uses of Microsoft extensions
562
563 fname-mangling-version-
564 C++ ObjC++ Joined
565
566 fnew-abi
567 C++ ObjC++
568
569 fnext-runtime
570 ObjC ObjC++
571 Generate code for NeXT (Apple Mac OS X) runtime environment
572
573 fnil-receivers
574 ObjC ObjC++
575 Assume that receivers of Objective-C messages may be nil
576
577 fnonansi-builtins
578 C++ ObjC++
579
580 fnonnull-objects
581 C++ ObjC++
582
583 fobjc-exceptions
584 ObjC ObjC++
585 Enable Objective-C exception and synchronization syntax
586
587 foperator-names
588 C++ ObjC++
589 Recognize C++ kewords like \"compl\" and \"xor\"
590
591 foptional-diags
592 C++ ObjC++
593 Enable optional diagnostics
594
595 fpch-deps
596 C ObjC C++ ObjC++
597
598 fpermissive
599 C++ ObjC++
600 Downgrade conformance errors to warnings
601
602 fpreprocessed
603 C ObjC C++ ObjC++
604 Treat the input file as already preprocessed
605
606 freplace-objc-classes
607 ObjC ObjC++
608 Used in Fix-and-Continue mode to indicate that object files may be swapped in at runtime
609
610 frepo
611 C++ ObjC++
612 Enable automatic template instantiation
613
614 frtti
615 C++ ObjC++
616 Generate run time type descriptor information
617
618 fshort-double
619 C ObjC C++ ObjC++
620 Use the same size for double as for float
621
622 fshort-enums
623 C ObjC C++ ObjC++
624 Use the narrowest integer type possible for enumeration types
625
626 fshort-wchar
627 C ObjC C++ ObjC++
628 Force the underlying type for \"wchar_t\" to be \"unsigned short\"
629
630 fshow-column
631 C ObjC C++ ObjC++
632
633 fsigned-bitfields
634 C ObjC C++ ObjC++
635 When \"signed\" or \"unsigned\" is not given make the bitfield signed
636
637 fsigned-char
638 C ObjC C++ ObjC++
639 Make \"char\" signed by default
640
641 fsquangle
642 C++ ObjC++
643
644 fstats
645 C++ ObjC++
646 Display statistics accumulated during compilation
647
648 fstrict-prototype
649 C++ ObjC++
650
651 ftabstop=
652 C ObjC C++ ObjC++ Joined RejectNegative UInteger
653 -ftabstop=<number> Distance between tab stops for column reporting
654
655 ftemplate-depth-
656 C++ ObjC++ Joined RejectNegative UInteger
657 -ftemplate-depth-<number> Specify maximum template instantiation depth
658
659 fthis-is-variable
660 C++ ObjC++
661
662 funsigned-bitfields
663 C ObjC C++ ObjC++
664 When \"signed\" or \"unsigned\" is not given make the bitfield unsigned
665
666 funsigned-char
667 C ObjC C++ ObjC++
668 Make \"char\" unsigned by default
669
670 fuse-cxa-atexit
671 C++ ObjC++
672 Use __cxa_atexit to register destructors
673
674 fvtable-gc
675 C++ ObjC++
676 Discard unused virtual functions
677
678 fvtable-thunks
679 C++ ObjC++
680 Implement vtables using thunks
681
682 fweak
683 C++ ObjC++
684 Emit common-like symbols as weak symbols
685
686 fwide-exec-charset=
687 C ObjC C++ ObjC++ Joined RejectNegative
688 -fwide-exec-charset=<cset> Convert all wide strings and character constants to character set <cset>
689
690 fworking-directory
691 C ObjC C++ ObjC++
692 Generate a #line directive pointing at the current working directory
693
694 fxref
695 C++ ObjC++
696 Emit cross referencing information
697
698 fzero-link
699 ObjC ObjC++
700 Generate lazy class lookup (via objc_getClass()) for use in Zero-Link mode
701
702 gen-decls
703 ObjC ObjC++
704 Dump declarations to a .decl file
705
706 idirafter
707 C ObjC C++ ObjC++ Joined Separate
708 -idirafter <dir> Add <dir> to the end of the system include path
709
710 imacros
711 C ObjC C++ ObjC++ Joined Separate
712 -imacros <file> Accept definition of macros in <file>
713
714 include
715 C ObjC C++ ObjC++ Joined Separate
716 -include <file> Include the contents of <file> before other files
717
718 iprefix
719 C ObjC C++ ObjC++ Joined Separate
720 -iprefix <path> Specify <path> as a prefix for next two options
721
722 isysroot
723 C ObjC C++ ObjC++ Joined Separate
724 -isysroot <dir> Set <dir> to be the system root directory
725
726 isystem
727 C ObjC C++ ObjC++ Joined Separate
728 -isystem <dir> Add <dir> to the start of the system include path
729
730 iquote
731 C ObjC C++ ObjC++ Joined Separate
732 -iquote <dir> Add <dir> to the end of the quote include path
733
734 iwithprefix
735 C ObjC C++ ObjC++ Joined Separate
736 -iwithprefix <dir> Add <dir> to the end of the system include path
737
738 iwithprefixbefore
739 C ObjC C++ ObjC++ Joined Separate
740 -iwithprefixbefore <dir> Add <dir> to the end of the main include path
741
742 lang-asm
743 C Undocumented
744
745 lang-objc
746 C ObjC C++ ObjC++ Undocumented
747
748 nostdinc
749 C ObjC C++ ObjC++
750 Do not search standard system include directories (those specified with -isystem will still be used)
751
752 nostdinc++
753 C++ ObjC++
754 Do not search standard system include directories for C++
755
756 o
757 C ObjC C++ ObjC++ Joined Separate
758 ; Documented in common.opt
759
760 pedantic
761 C ObjC C++ ObjC++
762 ; Documented in common.opt
763
764 pedantic-errors
765 C ObjC C++ ObjC++
766 ; Documented in common.opt
767
768 print-objc-runtime-info
769 ObjC ObjC++
770 Generate C header of platform-specific features
771
772 remap
773 C ObjC C++ ObjC++
774 Remap file names when including files
775
776 std=c++98
777 C++ ObjC++
778 Conform to the ISO 1998 C++ standard
779
780 std=c89
781 C ObjC
782 Conform to the ISO 1990 C standard
783
784 std=c99
785 C ObjC
786 Conform to the ISO 1999 C standard
787
788 std=c9x
789 C ObjC
790 Deprecated in favor of -std=c99
791
792 std=gnu++98
793 C++ ObjC++
794 Conform to the ISO 1998 C++ standard with GNU extensions
795
796 std=gnu89
797 C ObjC
798 Conform to the ISO 1990 C standard with GNU extensions
799
800 std=gnu99
801 C ObjC
802 Conform to the ISO 1999 C standard with GNU extensions
803
804 std=gnu9x
805 C ObjC
806 Deprecated in favor of -std=gnu99
807
808 std=iso9899:1990
809 C ObjC
810 Deprecated in favor of -std=c89
811
812 std=iso9899:199409
813 C ObjC
814 Conform to the ISO 1990 C standard as amended in 1994
815
816 std=iso9899:1999
817 C ObjC
818 Deprecated in favor of -std=c99
819
820 std=iso9899:199x
821 C ObjC
822 Deprecated in favor of -std=c99
823
824 traditional-cpp
825 C ObjC C++ ObjC++
826 Enable traditional preprocessing
827
828 trigraphs
829 C ObjC C++ ObjC++
830 -trigraphs Support ISO C trigraphs
831
832 undef
833 C ObjC C++ ObjC++
834 Do not predefine system-specific and GCC-specific macros
835
836 v
837 C ObjC C++ ObjC++
838 Enable verbose output
839
840 w
841 C ObjC C++ ObjC++
842 ; Documented in common.opt
843
844 ; This comment is to ensure we retain the blank line above.