Options.td revision 6994bb61eff86b2db53253ec74b24c4142fc080e
1//===--- DriverOptions.td - Options for clang -----------------------------===//
2//
3//                     The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9//
10//  This file defines the options accepted by clang.
11//
12//===----------------------------------------------------------------------===//
13
14// Include the common option parsing interfaces.
15include "OptParser.td"
16
17/////////
18// Groups
19
20// Meta-group which defines
21def CompileOnly_Group     : OptionGroup<"<CompileOnly group>">;
22def Action_Group          : OptionGroup<"<action group>">;
23
24def I_Group               : OptionGroup<"<I group>">, Group<CompileOnly_Group>;
25def L_Group               : OptionGroup<"<L group>">, Group<CompileOnly_Group>;
26def M_Group               : OptionGroup<"<M group>">, Group<CompileOnly_Group>;
27def T_Group               : OptionGroup<"<T group>">;
28def O_Group               : OptionGroup<"<O group>">, Group<CompileOnly_Group>;
29def W_Group               : OptionGroup<"<W group>">, Group<CompileOnly_Group>;
30def X_Group               : OptionGroup<"<X group>">;
31def a_Group               : OptionGroup<"<a group>">;
32def d_Group               : OptionGroup<"<d group>">;
33def f_Group               : OptionGroup<"<f group>">, Group<CompileOnly_Group>;
34def f_clang_Group         : OptionGroup<"<f (clang-only) group>">, Group<CompileOnly_Group>;
35def g_Group               : OptionGroup<"<g group>">;
36def g_flags_Group         : OptionGroup<"<g flags group>">;
37def i_Group               : OptionGroup<"<i group>">, Group<CompileOnly_Group>;
38def clang_i_Group         : OptionGroup<"<clang i group>">, Group<i_Group>;
39def m_Group               : OptionGroup<"<m group>">, Group<CompileOnly_Group>;
40def m_x86_Features_Group  : OptionGroup<"<m x86 features group>">, Group<m_Group>;
41def m_hexagon_Features_Group  : OptionGroup<"<m hexagon features group>">, Group<m_Group>;
42def u_Group               : OptionGroup<"<u group>">;
43
44def pedantic_Group        : OptionGroup<"<pedantic group>">,
45  Group<CompileOnly_Group>;
46def reserved_lib_Group   : OptionGroup<"<reserved libs group>">;
47
48// Temporary groups for clang options which we know we don't support,
49// but don't want to verbosely warn the user about.
50def clang_ignored_f_Group : OptionGroup<"<clang ignored f group>">,
51  Group<f_Group>;
52def clang_ignored_m_Group : OptionGroup<"<clang ignored m group>">,
53  Group<m_Group>;
54
55/////////
56// Options
57
58// The internal option ID must be a valid C++ identifier and results in a
59// clang::driver::options::OPT_XX enum constant for XX.
60//
61// We want to unambiguously be able to refer to options from the driver source
62// code, for this reason the option name is mangled into an ID. This mangling
63// isn't guaranteed to have an inverse, but for practical purposes it does.
64//
65// The mangling scheme is to ignore the leading '-', and perform the following
66// substitutions:
67//   _ => __
68//   - => _
69//   # => _HASH
70//   , => _COMMA
71//   = => _EQ
72//   C++ => CXX
73//   . => _
74
75// Developer Driver Options
76
77def ccc_Group : OptionGroup<"<clang internal options>">;
78def ccc_driver_Group : OptionGroup<"<clang driver internal options>">,
79  Group<ccc_Group>, HelpText<"DRIVER OPTIONS">;
80def ccc_debug_Group : OptionGroup<"<clang debug/development internal options>">,
81  Group<ccc_Group>, HelpText<"DEBUG/DEVELOPMENT OPTIONS">;
82
83class CCCDriverOpt : Group<ccc_driver_Group>, Flags<[DriverOption, HelpHidden]>;
84def ccc_cxx : Flag<"-ccc-cxx">, CCCDriverOpt,
85  HelpText<"Act as a C++ driver">;
86def ccc_echo : Flag<"-ccc-echo">, CCCDriverOpt,
87  HelpText<"Echo commands before running them">;
88def ccc_gcc_name : Separate<"-ccc-gcc-name">, CCCDriverOpt,
89  HelpText<"Name for native GCC compiler">,
90  MetaVarName<"<gcc-path>">;
91def ccc_clang_cxx : Flag<"-ccc-clang-cxx">, CCCDriverOpt,
92  HelpText<"Enable the clang compiler for C++">;
93def ccc_no_clang_cxx : Flag<"-ccc-no-clang-cxx">, CCCDriverOpt,
94  HelpText<"Disable the clang compiler for C++">;
95def ccc_no_clang : Flag<"-ccc-no-clang">, CCCDriverOpt,
96  HelpText<"Disable the clang compiler">;
97def ccc_no_clang_cpp : Flag<"-ccc-no-clang-cpp">, CCCDriverOpt,
98  HelpText<"Disable the clang preprocessor">;
99def ccc_clang_archs : Separate<"-ccc-clang-archs">, CCCDriverOpt,
100  HelpText<"Comma separate list of architectures to use the clang compiler for">,
101  MetaVarName<"<arch-list>">;
102def ccc_pch_is_pch : Flag<"-ccc-pch-is-pch">, CCCDriverOpt,
103  HelpText<"Use lazy PCH for precompiled headers">;
104def ccc_pch_is_pth : Flag<"-ccc-pch-is-pth">, CCCDriverOpt,
105  HelpText<"Use pretokenized headers for precompiled headers">;
106
107class CCCDebugOpt : Group<ccc_debug_Group>, Flags<[DriverOption, HelpHidden]>;
108def ccc_install_dir : Separate<"-ccc-install-dir">, CCCDebugOpt,
109  HelpText<"Simulate installation in the given directory">;
110def ccc_print_options : Flag<"-ccc-print-options">, CCCDebugOpt,
111  HelpText<"Dump parsed command line arguments">;
112def ccc_print_phases : Flag<"-ccc-print-phases">, CCCDebugOpt,
113  HelpText<"Dump list of actions to perform">;
114def ccc_print_bindings : Flag<"-ccc-print-bindings">, CCCDebugOpt,
115  HelpText<"Show bindings of tools to actions">;
116
117def ccc_arcmt_check : Flag<"-ccc-arcmt-check">, CCCDriverOpt,
118  HelpText<"Check for ARC migration issues that need manual handling">;
119def ccc_arcmt_modify : Flag<"-ccc-arcmt-modify">, CCCDriverOpt,
120  HelpText<"Apply modifications to files to conform to ARC">;
121def ccc_arrmt_check : Flag<"-ccc-arrmt-check">, Alias<ccc_arcmt_check>;
122def ccc_arrmt_modify : Flag<"-ccc-arrmt-modify">, Alias<ccc_arcmt_modify>;
123def ccc_arcmt_migrate : Separate<"-ccc-arcmt-migrate">, CCCDriverOpt,
124  HelpText<"Apply modifications and produces temporary files that conform to ARC">;
125def arcmt_migrate_report_output : Separate<"-arcmt-migrate-report-output">,
126  HelpText<"Output path for the plist report">,  Flags<[CC1Option]>;
127def arcmt_migrate_emit_arc_errors : Flag<"-arcmt-migrate-emit-errors">,
128  HelpText<"Emit ARC errors even if the migrator can fix them">,
129  Flags<[CC1Option]>;
130
131def _migrate : Flag<"--migrate">, Flags<[DriverOption]>,
132  HelpText<"Run the migrator">;
133def ccc_objcmt_migrate : Separate<"-ccc-objcmt-migrate">, CCCDriverOpt,
134  HelpText<"Apply modifications and produces temporary files to migrate to "
135   "modern ObjC syntax">;
136def objcmt_migrate_literals : Flag<"-objcmt-migrate-literals">, Flags<[CC1Option]>,
137  HelpText<"Enable migration to modern ObjC literals">;
138def objcmt_migrate_subscripting : Flag<"-objcmt-migrate-subscripting">, Flags<[CC1Option]>,
139  HelpText<"Enable migration to modern ObjC subscripting">;
140
141// Make sure all other -ccc- options are rejected.
142def ccc_ : Joined<"-ccc-">, Group<ccc_Group>, Flags<[Unsupported]>;
143
144// Standard Options
145
146def _HASH_HASH_HASH : Flag<"-###">, Flags<[DriverOption]>,
147    HelpText<"Print the commands to run for this compilation">;
148// The '--' option is here for the sake of compatibility with gcc, but is 
149// being ignored by the driver.
150def _DASH_DASH : Flag<"--">, Flags<[DriverOption]>;
151def A : JoinedOrSeparate<"-A">;
152def B : JoinedOrSeparate<"-B">;
153def CC : Flag<"-CC">, Flags<[CC1Option]>;
154def C : Flag<"-C">, Flags<[CC1Option]>;
155def D : JoinedOrSeparate<"-D">, Group<CompileOnly_Group>, Flags<[CC1Option]>;
156def E : Flag<"-E">, Flags<[DriverOption,CC1Option]>, Group<Action_Group>,
157  HelpText<"Only run the preprocessor">;
158def F : JoinedOrSeparate<"-F">, Flags<[RenderJoined,CC1Option]>,
159    HelpText<"Add directory to framework include search path">;
160def G : Separate<"-G">, Flags<[DriverOption]>;
161def H : Flag<"-H">, Flags<[CC1Option]>,
162    HelpText<"Show header includes and nesting depth">;
163def I_ : Flag<"-I-">, Group<I_Group>;
164def I : JoinedOrSeparate<"-I">, Group<I_Group>, Flags<[CC1Option]>,
165    HelpText<"Add directory to include search path">;
166def L : JoinedOrSeparate<"-L">, Flags<[RenderJoined]>;
167def MD : Flag<"-MD">, Group<M_Group>;
168def MF : JoinedOrSeparate<"-MF">, Group<M_Group>;
169def MG : Flag<"-MG">, Group<M_Group>, Flags<[CC1Option]>,
170    HelpText<"Add missing headers to dependency list">;
171def MMD : Flag<"-MMD">, Group<M_Group>;
172def MM : Flag<"-MM">, Group<M_Group>;
173def MP : Flag<"-MP">, Group<M_Group>, Flags<[CC1Option]>,
174    HelpText<"Create phony target for each dependency (other than main file)">;
175def MQ : JoinedOrSeparate<"-MQ">, Group<M_Group>, Flags<[CC1Option]>,
176    HelpText<"Specify target to quote for dependency">;
177def MT : JoinedOrSeparate<"-MT">, Group<M_Group>, Flags<[CC1Option]>,
178    HelpText<"Specify target for dependency">;
179def Mach : Flag<"-Mach">;
180def M : Flag<"-M">, Group<M_Group>;
181def O0 : Joined<"-O0">, Group<O_Group>, Flags<[CC1Option]>;
182def O4 : Joined<"-O4">, Group<O_Group>, Flags<[CC1Option]>;
183def ObjCXX : Flag<"-ObjC++">, Flags<[DriverOption]>,
184  HelpText<"Treat source input files as Objective-C++ inputs">;
185def ObjC : Flag<"-ObjC">, Flags<[DriverOption]>,
186  HelpText<"Treat source input files as Objective-C inputs">;
187def O : Joined<"-O">, Group<O_Group>, Flags<[CC1Option]>;
188def P : Flag<"-P">, Flags<[CC1Option]>,
189  HelpText<"Disable linemarker output in -E mode">;
190def Qn : Flag<"-Qn">;
191def Qunused_arguments : Flag<"-Qunused-arguments">, Flags<[DriverOption]>,
192  HelpText<"Don't emit warning for unused driver arguments">;
193def Q : Flag<"-Q">;
194def R : Flag<"-R">;
195def S : Flag<"-S">, Flags<[DriverOption,CC1Option]>, Group<Action_Group>,
196  HelpText<"Only run preprocess and compilation steps">;
197def Tbss : JoinedOrSeparate<"-Tbss">, Group<T_Group>;
198def Tdata : JoinedOrSeparate<"-Tdata">, Group<T_Group>;
199def Ttext : JoinedOrSeparate<"-Ttext">, Group<T_Group>;
200def T : JoinedOrSeparate<"-T">, Group<T_Group>;
201def U : JoinedOrSeparate<"-U">, Group<CompileOnly_Group>, Flags<[CC1Option]>;
202def V : JoinedOrSeparate<"-V">, Flags<[DriverOption, Unsupported]>;
203def Wa_COMMA : CommaJoined<"-Wa,">,
204  HelpText<"Pass the comma separated arguments in <arg> to the assembler">,
205  MetaVarName<"<arg>">;
206def Wall : Flag<"-Wall">, Group<W_Group>, Flags<[CC1Option]>;
207def Wdeprecated : Flag<"-Wdeprecated">, Group<W_Group>, Flags<[CC1Option]>;
208def Wno_deprecated : Flag<"-Wno-deprecated">, Group<W_Group>, Flags<[CC1Option]>;
209def Wextra : Flag<"-Wextra">, Group<W_Group>, Flags<[CC1Option]>;
210def Wl_COMMA : CommaJoined<"-Wl,">, Flags<[LinkerInput, RenderAsInput]>,
211  HelpText<"Pass the comma separated arguments in <arg> to the linker">,
212  MetaVarName<"<arg>">;
213def Wno_nonportable_cfstrings : Joined<"-Wno-nonportable-cfstrings">, Group<W_Group>,
214  Flags<[CC1Option]>;
215def Wnonportable_cfstrings : Joined<"-Wnonportable-cfstrings">, Group<W_Group>,
216  Flags<[CC1Option]>;
217def Wp_COMMA : CommaJoined<"-Wp,">,
218  HelpText<"Pass the comma separated arguments in <arg> to the preprocessor">,
219  MetaVarName<"<arg>">;
220def Wwrite_strings : Flag<"-Wwrite-strings">, Group<W_Group>, Flags<[CC1Option]>;
221def Wno_write_strings : Flag<"-Wno-write-strings">, Group<W_Group>, Flags<[CC1Option]>;
222def W_Joined : Joined<"-W">, Group<W_Group>, Flags<[CC1Option]>;
223def Xanalyzer : Separate<"-Xanalyzer">,
224  HelpText<"Pass <arg> to the static analyzer">, MetaVarName<"<arg>">;
225def Xarch__ : JoinedAndSeparate<"-Xarch_">, Flags<[DriverOption]>;
226def Xassembler : Separate<"-Xassembler">,
227  HelpText<"Pass <arg> to the assembler">, MetaVarName<"<arg>">;
228def Xclang : Separate<"-Xclang">,
229  HelpText<"Pass <arg> to the clang compiler">, MetaVarName<"<arg>">,
230  Flags<[NoForward]>;
231def Xlinker : Separate<"-Xlinker">, Flags<[LinkerInput, RenderAsInput]>,
232  HelpText<"Pass <arg> to the linker">, MetaVarName<"<arg>">;
233def Xpreprocessor : Separate<"-Xpreprocessor">,
234  HelpText<"Pass <arg> to the preprocessor">, MetaVarName<"<arg>">;
235def X_Flag : Flag<"-X">;
236def X_Joined : Joined<"-X">;
237def Z_Flag : Flag<"-Z">;
238def Z_Joined : Joined<"-Z">;
239def all__load : Flag<"-all_load">;
240def allowable__client : Separate<"-allowable_client">;
241def ansi : Flag<"-ansi">, Group<a_Group>;
242def arch__errors__fatal : Flag<"-arch_errors_fatal">;
243def arch : Separate<"-arch">, Flags<[DriverOption]>;
244def arch__only : Separate<"-arch_only">;
245def a : Joined<"-a">, Group<a_Group>;
246def bind__at__load : Flag<"-bind_at_load">;
247def bundle__loader : Separate<"-bundle_loader">;
248def bundle : Flag<"-bundle">;
249def b : JoinedOrSeparate<"-b">, Flags<[Unsupported]>;
250def client__name : JoinedOrSeparate<"-client_name">;
251def combine : Flag<"-combine">, Flags<[DriverOption, Unsupported]>;
252def compatibility__version : JoinedOrSeparate<"-compatibility_version">;
253def coverage : Flag<"-coverage">;
254def cpp_precomp : Flag<"-cpp-precomp">, Group<clang_ignored_f_Group>;
255def current__version : JoinedOrSeparate<"-current_version">;
256def cxx_isystem : JoinedOrSeparate<"-cxx-isystem">, Group<clang_i_Group>,
257  HelpText<"Add directory to the C++ SYSTEM include search path">, Flags<[CC1Option]>,
258  MetaVarName<"<directory>">;
259def c : Flag<"-c">, Flags<[DriverOption]>,
260  HelpText<"Only run preprocess, compile, and assemble steps">;
261def dA : Flag<"-dA">, Group<d_Group>;
262def dD : Flag<"-dD">, Group<d_Group>, Flags<[CC1Option]>,
263  HelpText<"Print macro definitions in -E mode in addition to normal output">;
264def dM : Flag<"-dM">, Group<d_Group>, Flags<[CC1Option]>,
265  HelpText<"Print macro definitions in -E mode instead of normal output">;
266def dead__strip : Flag<"-dead_strip">;
267def dependency_file : Separate<"-dependency-file">, Flags<[CC1Option]>,
268  HelpText<"Filename (or -) to write dependency output to">;
269def dependency_dot : Separate<"-dependency-dot">, Flags<[CC1Option]>,
270  HelpText<"Filename to write DOT-formatted header dependencies to">;
271def dumpmachine : Flag<"-dumpmachine">;
272def dumpspecs : Flag<"-dumpspecs">, Flags<[Unsupported]>;
273def dumpversion : Flag<"-dumpversion">;
274def dylib__file : Separate<"-dylib_file">;
275def dylinker__install__name : JoinedOrSeparate<"-dylinker_install_name">;
276def dylinker : Flag<"-dylinker">;
277def dynamiclib : Flag<"-dynamiclib">;
278def dynamic : Flag<"-dynamic">, Flags<[NoArgumentUnused]>;
279def d_Flag : Flag<"-d">, Group<d_Group>;
280def d_Joined : Joined<"-d">, Group<d_Group>;
281def emit_ast : Flag<"-emit-ast">,
282  HelpText<"Emit Clang AST files for source inputs">;
283def emit_llvm : Flag<"-emit-llvm">, Flags<[CC1Option]>, Group<Action_Group>,
284  HelpText<"Use the LLVM representation for assembler and object files">;
285def exported__symbols__list : Separate<"-exported_symbols_list">;
286def e : JoinedOrSeparate<"-e">;
287def fPIC : Flag<"-fPIC">, Group<f_Group>;
288def fno_PIC : Flag<"-fno-PIC">, Group<f_Group>;
289def fPIE : Flag<"-fPIE">, Group<f_Group>;
290def fno_PIE : Flag<"-fno-PIE">, Group<f_Group>;
291def faccess_control : Flag<"-faccess-control">, Group<f_Group>;
292def fallow_unsupported : Flag<"-fallow-unsupported">, Group<f_Group>;
293def faltivec : Flag<"-faltivec">, Group<f_Group>, Flags<[CC1Option]>,
294  HelpText<"Enable AltiVec vector initializer syntax">;
295def fapple_kext : Flag<"-fapple-kext">, Group<f_Group>, Flags<[CC1Option]>,
296  HelpText<"Use Apple's kernel extensions ABI">;
297def fapple_pragma_pack : Flag<"-fapple-pragma-pack">, Group<f_Group>, Flags<[CC1Option]>,
298  HelpText<"Enable Apple gcc-compatible #pragma pack handling">;
299def faddress_sanitizer : Flag<"-faddress-sanitizer">, Group<f_Group>, Flags<[CC1Option]>,
300  HelpText<"Enable AddressSanitizer instrumentation (memory error detection)">;
301def fno_address_sanitizer : Flag<"-fno-address-sanitizer">, Group<f_Group>, Flags<[CC1Option]>;
302def fthread_sanitizer : Flag<"-fthread-sanitizer">, Group<f_Group>, Flags<[CC1Option]>,
303  HelpText<"Enable ThreadSanitizer instrumentation (race detection)">;
304def fno_thread_sanitizer : Flag<"-fno-thread-sanitizer">, Group<f_Group>, Flags<[CC1Option]>;
305def fasm : Flag<"-fasm">, Group<f_Group>;
306
307def fasm_blocks : Flag<"-fasm-blocks">, Group<f_Group>;
308def fno_asm_blocks : Flag<"-fno-asm-blocks">, Group<f_Group>;
309
310def fassume_sane_operator_new : Flag<"-fassume-sane-operator-new">, Group<f_Group>;
311def fastcp : Flag<"-fastcp">, Group<f_Group>;
312def fastf : Flag<"-fastf">, Group<f_Group>;
313def fast : Flag<"-fast">, Group<f_Group>;
314def fasynchronous_unwind_tables : Flag<"-fasynchronous-unwind-tables">, Group<f_Group>;
315def fblocks : Flag<"-fblocks">, Group<f_Group>, Flags<[CC1Option]>,
316  HelpText<"Enable the 'blocks' language feature">;
317def fbootclasspath_EQ : Joined<"-fbootclasspath=">, Group<f_Group>;
318def fborland_extensions : Flag<"-fborland-extensions">, Group<f_Group>, Flags<[CC1Option]>,
319  HelpText<"Accept non-standard constructs supported by the Borland compiler">;
320def fbounds_checking : Flag<"-fbounds-checking">, Group<f_Group>,
321  HelpText<"Enable run-time bounds checks.">;
322def fbounds_checking_EQ : Joined<"-fbounds-checking=">, Flags<[CC1Option]>,
323  Group<f_Group>;
324def fbuiltin_strcat : Flag<"-fbuiltin-strcat">, Group<f_Group>;
325def fbuiltin_strcpy : Flag<"-fbuiltin-strcpy">, Group<f_Group>;
326def fbuiltin : Flag<"-fbuiltin">, Group<f_Group>;
327def fcaret_diagnostics : Flag<"-fcaret-diagnostics">, Group<f_Group>;
328def fcatch_undefined_behavior : Flag<"-fcatch-undefined-behavior">, Flags<[CC1Option]>,
329  Group<f_Group>, HelpText<"Generate runtime checks for undefined behavior.">;
330def fclasspath_EQ : Joined<"-fclasspath=">, Group<f_Group>;
331def fcolor_diagnostics : Flag<"-fcolor-diagnostics">, Group<f_Group>, Flags<[CC1Option]>,
332  HelpText<"Use colors in diagnostics">;
333def fcommon : Flag<"-fcommon">, Group<f_Group>;
334def fcompile_resource_EQ : Joined<"-fcompile-resource=">, Group<f_Group>;
335def fconstant_cfstrings : Flag<"-fconstant-cfstrings">, Group<f_Group>;
336def fconstant_string_class_EQ : Joined<"-fconstant-string-class=">, Group<f_Group>;
337def fconstexpr_depth_EQ : Joined<"-fconstexpr-depth=">, Group<f_Group>;
338def fconstexpr_backtrace_limit_EQ : Joined<"-fconstexpr-backtrace-limit=">,
339                                    Group<f_Group>;
340def fno_crash_diagnostics : Flag<"-fno-crash-diagnostics">, Group<f_clang_Group>, Flags<[NoArgumentUnused]>;
341def fcreate_profile : Flag<"-fcreate-profile">, Group<f_Group>;
342def fcxx_exceptions: Flag<"-fcxx-exceptions">, Group<f_Group>,
343  HelpText<"Enable C++ exceptions">, Flags<[CC1Option]>;
344def fcxx_modules : Flag <"-fcxx-modules">, Group<f_Group>, Flags<[NoForward]>;
345def fdebug_pass_arguments : Flag<"-fdebug-pass-arguments">, Group<f_Group>;
346def fdebug_pass_structure : Flag<"-fdebug-pass-structure">, Group<f_Group>;
347def fdiagnostics_fixit_info : Flag<"-fdiagnostics-fixit-info">, Group<f_clang_Group>;
348def fdiagnostics_parseable_fixits : Flag<"-fdiagnostics-parseable-fixits">, Group<f_clang_Group>,
349    Flags<[CC1Option]>, HelpText<"Print fix-its in machine parseable form">;
350def fdiagnostics_print_source_range_info : Flag<"-fdiagnostics-print-source-range-info">,
351    Group<f_clang_Group>,  Flags<[CC1Option]>,
352    HelpText<"Print source range spans in numeric form">;
353def fdiagnostics_show_option : Flag<"-fdiagnostics-show-option">, Group<f_Group>,
354    Flags<[CC1Option]>, HelpText<"Print option name with mappable diagnostics">;
355def fdiagnostics_show_name : Flag<"-fdiagnostics-show-name">, Group<f_Group>,
356    Flags<[CC1Option]>, HelpText<"Print diagnostic name">;
357def fdiagnostics_show_note_include_stack : Flag<"-fdiagnostics-show-note-include-stack">,
358    Group<f_Group>,  Flags<[CC1Option]>, HelpText<"Display include stacks for diagnostic notes">;
359def fdiagnostics_format_EQ : Joined<"-fdiagnostics-format=">, Group<f_clang_Group>;
360def fdiagnostics_show_category_EQ : Joined<"-fdiagnostics-show-category=">, Group<f_clang_Group>;
361def fdiagnostics_show_template_tree : Flag<"-fdiagnostics-show-template-tree">,
362    Group<f_Group>, Flags<[CC1Option]>,
363    HelpText<"Print a template comparison tree for differing templates">;
364def fdollars_in_identifiers : Flag<"-fdollars-in-identifiers">, Group<f_Group>,
365  HelpText<"Allow '$' in identifiers">, Flags<[CC1Option]>;
366def fdwarf2_cfi_asm : Flag<"-fdwarf2-cfi-asm">, Group<f_Group>;
367def fno_dwarf2_cfi_asm : Flag<"-fno-dwarf2-cfi-asm">, Group<f_Group>,  Flags<[CC1Option]>;
368def fdwarf_directory_asm : Flag<"-fdwarf-directory-asm">, Group<f_Group>;
369def fno_dwarf_directory_asm : Flag<"-fno-dwarf-directory-asm">, Group<f_Group>, Flags<[CC1Option]>;
370def felide_constructors : Flag<"-felide-constructors">, Group<f_Group>;
371def fno_elide_type : Flag<"-fno-elide-type">, Group<f_Group>,
372    Flags<[CC1Option]>,
373    HelpText<"Do not elide types when printing diagnostics">;
374def feliminate_unused_debug_symbols : Flag<"-feliminate-unused-debug-symbols">, Group<f_Group>;
375def femit_all_decls : Flag<"-femit-all-decls">, Group<f_Group>, Flags<[CC1Option]>,
376  HelpText<"Emit all declarations, even if unused">;
377def fencoding_EQ : Joined<"-fencoding=">, Group<f_Group>;
378def ferror_limit_EQ : Joined<"-ferror-limit=">, Group<f_Group>;
379def fexceptions : Flag<"-fexceptions">, Group<f_Group>, Flags<[CC1Option]>,
380  HelpText<"Enable support for exception handling">;
381def fextdirs_EQ : Joined<"-fextdirs=">, Group<f_Group>;
382def fhosted : Flag<"-fhosted">, Group<f_Group>;
383def ffast_math : Flag<"-ffast-math">, Group<f_Group>, Flags<[CC1Option]>,
384  HelpText<"Enable the *frontend*'s 'fast-math' mode. This has no effect on "
385           "optimizations, but provides a preprocessor macro __FAST_MATH__ the "
386           "same as GCC's -ffast-math flag.">;
387def fmath_errno : Flag<"-fmath-errno">, Group<f_Group>, Flags<[CC1Option]>,
388  HelpText<"Require math functions to indicate errors by setting errno">;
389def fno_math_errno : Flag<"-fno-math-errno">, Group<f_Group>;
390def fsignaling_math : Flag<"-fsignaling-math">, Group<f_Group>;
391def fno_signaling_math : Flag<"-fno-signaling-math">, Group<f_Group>;
392def funsafe_math_optimizations : Flag<"-funsafe-math-optimizations">,
393  Group<f_Group>;
394def fno_unsafe_math_optimizations : Flag<"-fno-unsafe-math-optimizations">,
395  Group<f_Group>;
396def fassociative_math : Flag<"-fassociative-math">, Group<f_Group>;
397def fno_associative_math : Flag<"-fno-associative-math">, Group<f_Group>;
398def freciprocal_math : Flag<"-freciprocal-math">, Group<f_Group>;
399def fno_reciprocal_math : Flag<"-fno-reciprocal-math">, Group<f_Group>;
400def ffinite_math_only : Flag<"-ffinite-math-only">, Group<f_Group>;
401def fno_finite_math_only : Flag<"-fno-finite-math-only">, Group<f_Group>;
402def fsigned_zeros : Flag<"-fsigned-zeros">, Group<f_Group>;
403def fno_signed_zeros : Flag<"-fno-signed-zeros">, Group<f_Group>;
404def fhonor_nans : Flag<"-fhonor-nans">, Group<f_Group>;
405def fno_honor_nans : Flag<"-fno-honor-nans">, Group<f_Group>;
406def fhonor_infinities : Flag<"-fhonor-infinities">, Group<f_Group>;
407def fno_honor_infinities : Flag<"-fno-honor-infinities">, Group<f_Group>;
408// Sic. This option was misspelled originally.
409def fhonor_infinites : Flag<"-fhonor-infinites">, Alias<fhonor_infinities>;
410def fno_honor_infinites : Flag<"-fno-honor-infinites">, Alias<fno_honor_infinities>;
411def ftrapping_math : Flag<"-ftrapping-math">, Group<f_Group>;
412def fno_trapping_math : Flag<"-fno-trapping-math">, Group<f_Group>;
413def ffp_contract : Joined<"-ffp-contract=">, Group<f_Group>,
414  Flags<[CC1Option]>, HelpText<"Form fused FP ops (e.g. FMAs): fast (everywhere)"
415  " | on (according to FP_CONTRACT pragma, default) | off (never fuse)">;
416
417def ffor_scope : Flag<"-ffor-scope">, Group<f_Group>;
418def fno_for_scope : Flag<"-fno-for-scope">, Group<f_Group>;
419
420def frewrite_includes : Flag<"-frewrite-includes">, Group<f_Group>,
421  Flags<[CC1Option]>;
422def fno_rewrite_includes : Flag<"-fno-rewrite-includes">, Group<f_Group>;
423
424def ffreestanding : Flag<"-ffreestanding">, Group<f_Group>, Flags<[CC1Option]>,
425  HelpText<"Assert that the compilation takes place in a freestanding environment">;
426def fgnu_keywords : Flag<"-fgnu-keywords">, Group<f_Group>, Flags<[CC1Option]>,
427  HelpText<"Allow GNU-extension keywords regardless of language standard">;
428def fgnu89_inline : Flag<"-fgnu89-inline">, Group<f_Group>, Flags<[CC1Option]>,
429  HelpText<"Use the gnu89 inline semantics">;
430def fno_gnu89_inline : Flag<"-fno-gnu89-inline">, Group<f_Group>;
431def fgnu_runtime : Flag<"-fgnu-runtime">, Group<f_Group>,
432  HelpText<"Generate output compatible with the standard GNU Objective-C runtime">;
433def fheinous_gnu_extensions : Flag<"-fheinous-gnu-extensions">, Flags<[CC1Option]>;
434def filelist : Separate<"-filelist">, Flags<[LinkerInput]>;
435def findirect_virtual_calls : Flag<"-findirect-virtual-calls">, Alias<fapple_kext>;
436def finline_functions : Flag<"-finline-functions">, Group<clang_ignored_f_Group>;
437def finline : Flag<"-finline">, Group<clang_ignored_f_Group>;
438def finstrument_functions : Flag<"-finstrument-functions">, Group<f_Group>, Flags<[CC1Option]>,
439  HelpText<"Generate calls to instrument function entry and exit">;
440def fkeep_inline_functions : Flag<"-fkeep-inline-functions">, Group<clang_ignored_f_Group>;
441def flat__namespace : Flag<"-flat_namespace">;
442def flax_vector_conversions : Flag<"-flax-vector-conversions">, Group<f_Group>;
443def flimit_debug_info : Flag<"-flimit-debug-info">, Group<f_Group>, Flags<[CC1Option]>,
444  HelpText<"Limit debug information produced to reduce size of debug binary">;
445def flimited_precision_EQ : Joined<"-flimited-precision=">, Group<f_Group>;
446def flto : Flag<"-flto">, Group<f_Group>;
447def fno_lto : Flag<"-fno-lto">, Group<f_Group>;
448def fmacro_backtrace_limit_EQ : Joined<"-fmacro-backtrace-limit=">,
449                                Group<f_Group>;
450def fmerge_all_constants : Flag<"-fmerge-all-constants">, Group<f_Group>;
451def fmessage_length_EQ : Joined<"-fmessage-length=">, Group<f_Group>;
452def fms_extensions : Flag<"-fms-extensions">, Group<f_Group>, Flags<[CC1Option]>,
453  HelpText<"Accept some non-standard constructs supported by the Microsoft compiler">;
454def fms_compatibility : Flag<"-fms-compatibility">, Group<f_Group>, Flags<[CC1Option]>,
455  HelpText<"Enable Microsoft compatibility mode">;
456def fmsc_version : Joined<"-fmsc-version=">, Group<f_Group>, Flags<[CC1Option]>,
457  HelpText<"Version of the Microsoft C/C++ compiler to report in _MSC_VER (0 = don't define it (default))">;
458def fdelayed_template_parsing : Flag<"-fdelayed-template-parsing">, Group<f_Group>,
459  HelpText<"Parse templated function definitions at the end of the "
460           "translation unit ">,  Flags<[CC1Option]>;
461def fmodule_cache_path : Separate<"-fmodule-cache-path">, Group<i_Group>, 
462  Flags<[NoForward,CC1Option]>, MetaVarName<"<directory>">,
463  HelpText<"Specify the module cache path">;
464def fmodules : Flag <"-fmodules">, Group<f_Group>, Flags<[NoForward,CC1Option]>,
465  HelpText<"Enable the 'modules' language feature">;
466  
467def fmudflapth : Flag<"-fmudflapth">, Group<f_Group>;
468def fmudflap : Flag<"-fmudflap">, Group<f_Group>;
469def fnested_functions : Flag<"-fnested-functions">, Group<f_Group>;
470def fnext_runtime : Flag<"-fnext-runtime">, Group<f_Group>;
471def fno_access_control : Flag<"-fno-access-control">, Group<f_Group>, Flags<[CC1Option]>,
472  HelpText<"Disable C++ access control">;
473def fno_apple_pragma_pack : Flag<"-fno-apple-pragma-pack">, Group<f_Group>;
474def fno_asm : Flag<"-fno-asm">, Group<f_Group>;
475def fno_asynchronous_unwind_tables : Flag<"-fno-asynchronous-unwind-tables">, Group<f_Group>;
476def fno_assume_sane_operator_new : Flag<"-fno-assume-sane-operator-new">, Group<f_Group>,
477  HelpText<"Don't assume that C++'s global operator new can't alias any pointer">,
478  Flags<[CC1Option]>;
479def fno_blocks : Flag<"-fno-blocks">, Group<f_Group>;
480def fno_borland_extensions : Flag<"-fno-borland-extensions">, Group<f_Group>;
481def fno_builtin_strcat : Flag<"-fno-builtin-strcat">, Group<f_Group>;
482def fno_builtin_strcpy : Flag<"-fno-builtin-strcpy">, Group<f_Group>;
483def fno_builtin : Flag<"-fno-builtin">, Group<f_Group>, Flags<[CC1Option]>,
484  HelpText<"Disable implicit builtin knowledge of functions">;
485def fno_caret_diagnostics : Flag<"-fno-caret-diagnostics">, Group<f_Group>,
486 Flags<[CC1Option]>;
487def fno_color_diagnostics : Flag<"-fno-color-diagnostics">, Group<f_Group>;
488def fno_common : Flag<"-fno-common">, Group<f_Group>, Flags<[CC1Option]>,
489    HelpText<"Compile common globals like normal definitions">;
490def fno_constant_cfstrings : Flag<"-fno-constant-cfstrings">, Group<f_Group>,
491  Flags<[CC1Option]>,
492  HelpText<"Disable creation of CodeFoundation-type constant strings">;
493def fno_cxx_exceptions: Flag<"-fno-cxx-exceptions">, Group<f_Group>;
494def fno_cxx_modules : Flag <"-fno-cxx-modules">, Group<f_Group>, Flags<[NoForward]>;
495def fno_diagnostics_fixit_info : Flag<"-fno-diagnostics-fixit-info">, Group<f_Group>,
496  Flags<[CC1Option]>, HelpText<"Do not include fixit information in diagnostics">;
497def fno_diagnostics_show_name : Flag<"-fno-diagnostics-show-name">, Group<f_Group>;
498def fno_diagnostics_show_option : Flag<"-fno-diagnostics-show-option">, Group<f_Group>;
499def fno_diagnostics_show_note_include_stack : Flag<"-fno-diagnostics-show-note-include-stack">,
500    Flags<[CC1Option]>, Group<f_Group>, HelpText<"Display include stacks for diagnostic notes">;
501def fno_dollars_in_identifiers : Flag<"-fno-dollars-in-identifiers">, Group<f_Group>,
502  HelpText<"Disallow '$' in identifiers">, Flags<[CC1Option]>;
503def fno_elide_constructors : Flag<"-fno-elide-constructors">, Group<f_Group>,
504  HelpText<"Disable C++ copy constructor elision">, Flags<[CC1Option]>;
505def fno_eliminate_unused_debug_symbols : Flag<"-fno-eliminate-unused-debug-symbols">, Group<f_Group>;
506def fno_exceptions : Flag<"-fno-exceptions">, Group<f_Group>;
507def fno_gnu_keywords : Flag<"-fno-gnu-keywords">, Group<f_Group>, Flags<[CC1Option]>;
508def fno_inline_functions : Flag<"-fno-inline-functions">, Group<f_clang_Group>, Flags<[CC1Option]>;
509def fno_inline : Flag<"-fno-inline">, Group<f_clang_Group>, Flags<[CC1Option]>;
510def fno_keep_inline_functions : Flag<"-fno-keep-inline-functions">, Group<clang_ignored_f_Group>;
511def fno_lax_vector_conversions : Flag<"-fno-lax-vector-conversions">, Group<f_Group>,
512  HelpText<"Disallow implicit conversions between vectors with a different number of elements or different element types">, Flags<[CC1Option]>;
513def fno_limit_debug_info : Flag<"-fno-limit-debug-info">, Group<f_Group>, Flags<[CC1Option]>,
514  HelpText<"Do not limit debug information produced to reduce size of debug binary">;
515def fno_merge_all_constants : Flag<"-fno-merge-all-constants">, Group<f_Group>,
516    Flags<[CC1Option]>, HelpText<"Disallow merging of constants.">;
517def fno_modules : Flag <"-fno-modules">, Group<f_Group>, Flags<[NoForward]>;
518def fno_ms_extensions : Flag<"-fno-ms-extensions">, Group<f_Group>;
519def fno_ms_compatibility : Flag<"-fno-ms-compatibility">, Group<f_Group>;
520def fno_delayed_template_parsing : Flag<"-fno-delayed-template-parsing">, Group<f_Group>;
521def fno_objc_exceptions: Flag<"-fno-objc-exceptions">, Group<f_Group>;
522def fno_objc_legacy_dispatch : Flag<"-fno-objc-legacy-dispatch">, Group<f_Group>;
523def fno_omit_frame_pointer : Flag<"-fno-omit-frame-pointer">, Group<f_Group>;
524def fno_operator_names : Flag<"-fno-operator-names">, Group<f_Group>,
525  HelpText<"Do not treat C++ operator name keywords as synonyms for operators">,
526  Flags<[CC1Option]>;
527def fno_pascal_strings : Flag<"-fno-pascal-strings">, Group<f_Group>;
528def fno_rtti : Flag<"-fno-rtti">, Group<f_Group>, Flags<[CC1Option]>,
529  HelpText<"Disable generation of rtti information">;
530def fno_short_enums : Flag<"-fno-short-enums">, Group<f_Group>;
531def fno_show_column : Flag<"-fno-show-column">, Group<f_Group>, Flags<[CC1Option]>,
532  HelpText<"Do not include column number on diagnostics">;
533def fno_show_source_location : Flag<"-fno-show-source-location">, Group<f_Group>,
534  Flags<[CC1Option]>, HelpText<"Do not include source location information with diagnostics">;
535def fno_spell_checking : Flag<"-fno-spell-checking">, Group<f_Group>,
536  Flags<[CC1Option]>, HelpText<"Disable spell-checking">;
537def fno_stack_protector : Flag<"-fno-stack-protector">, Group<f_Group>;
538def fno_strict_aliasing : Flag<"-fno-strict-aliasing">, Group<f_Group>;
539def fno_strict_enums : Flag<"-fno-strict-enums">, Group<f_Group>;
540def fno_strict_overflow : Flag<"-fno-strict-overflow">, Group<f_Group>;
541def fno_threadsafe_statics : Flag<"-fno-threadsafe-statics">, Group<f_Group>,
542  Flags<[CC1Option]>, HelpText<"Do not emit code to make initialization of local statics thread safe">;
543def fno_use_cxa_atexit : Flag<"-fno-use-cxa-atexit">, Group<f_Group>, Flags<[CC1Option]>,
544  HelpText<"Don't use __cxa_atexit for calling destructors">;
545def fno_unit_at_a_time : Flag<"-fno-unit-at-a-time">, Group<f_Group>;
546def fno_unwind_tables : Flag<"-fno-unwind-tables">, Group<f_Group>;
547def fno_verbose_asm : Flag<"-fno-verbose-asm">, Group<f_Group>;
548def fno_working_directory : Flag<"-fno-working-directory">, Group<f_Group>;
549def fno_wrapv : Flag<"-fno-wrapv">, Group<f_Group>;
550def fno_zero_initialized_in_bss : Flag<"-fno-zero-initialized-in-bss">, Group<f_Group>;
551def fobjc_arc : Flag<"-fobjc-arc">, Group<f_Group>, Flags<[CC1Option]>,
552  HelpText<"Synthesize retain and release calls for Objective-C pointers">;
553def fno_objc_arc : Flag<"-fno-objc-arc">, Group<f_Group>;
554def fobjc_arc_exceptions : Flag<"-fobjc-arc-exceptions">, Group<f_Group>, Flags<[CC1Option]>,
555  HelpText<"Use EH-safe code when synthesizing retains and releases in -fobjc-arc">;
556def fno_objc_arc_exceptions : Flag<"-fno-objc-arc-exceptions">, Group<f_Group>;
557def fobjc_atdefs : Flag<"-fobjc-atdefs">, Group<clang_ignored_f_Group>;
558def fobjc_call_cxx_cdtors : Flag<"-fobjc-call-cxx-cdtors">, Group<clang_ignored_f_Group>;
559def fobjc_exceptions: Flag<"-fobjc-exceptions">, Group<f_Group>,
560  HelpText<"Enable Objective-C exceptions">, Flags<[CC1Option]>;
561
562def fobjc_gc_only : Flag<"-fobjc-gc-only">, Group<f_Group>, Flags<[CC1Option]>,
563  HelpText<"Use GC exclusively for Objective-C related memory management">;
564def fobjc_gc : Flag<"-fobjc-gc">, Group<f_Group>, Flags<[CC1Option]>,
565  HelpText<"Enable Objective-C garbage collection">;
566def fobjc_legacy_dispatch : Flag<"-fobjc-legacy-dispatch">, Group<f_Group>;
567def fobjc_new_property : Flag<"-fobjc-new-property">, Group<clang_ignored_f_Group>;
568def fobjc_infer_related_result_type : Flag<"-fobjc-infer-related-result-type">, 
569                                      Group<f_Group>;
570def fno_objc_infer_related_result_type : Flag<
571  "-fno-objc-infer-related-result-type">, Group<f_Group>,
572  HelpText<
573    "do not infer Objective-C related result type based on method family">,
574  Flags<[CC1Option]>;
575def fobjc_link_runtime: Flag<"-fobjc-link-runtime">, Group<f_Group>;
576
577// Objective-C ABI options.
578def fobjc_runtime_EQ : Joined<"-fobjc-runtime=">, Group<f_Group>, Flags<[CC1Option]>,
579  HelpText<"Specify the target Objective-C runtime kind and version">;
580def fobjc_abi_version_EQ : Joined<"-fobjc-abi-version=">, Group<f_Group>;
581def fobjc_nonfragile_abi_version_EQ : Joined<"-fobjc-nonfragile-abi-version=">, Group<f_Group>;
582def fobjc_nonfragile_abi : Flag<"-fobjc-nonfragile-abi">, Group<f_Group>;
583def fno_objc_nonfragile_abi : Flag<"-fno-objc-nonfragile-abi">, Group<f_Group>;
584
585def fobjc_sender_dependent_dispatch : Flag<"-fobjc-sender-dependent-dispatch">, Group<f_Group>;
586def fobjc : Flag<"-fobjc">, Group<f_Group>;
587def fomit_frame_pointer : Flag<"-fomit-frame-pointer">, Group<f_Group>;
588def fopenmp : Flag<"-fopenmp">, Group<f_Group>;
589def fno_optimize_sibling_calls : Flag<"-fno-optimize-sibling-calls">, Group<f_Group>;
590def foptimize_sibling_calls : Flag<"-foptimize-sibling-calls">, Group<f_Group>;
591def force__cpusubtype__ALL : Flag<"-force_cpusubtype_ALL">;
592def force__flat__namespace : Flag<"-force_flat_namespace">;
593def force__load : Separate<"-force_load">;
594def foutput_class_dir_EQ : Joined<"-foutput-class-dir=">, Group<f_Group>;
595def fpack_struct : Flag<"-fpack-struct">, Group<f_Group>;
596def fno_pack_struct : Flag<"-fno-pack-struct">, Group<f_Group>;
597def fpack_struct_EQ : Joined<"-fpack-struct=">, Group<f_Group>, Flags<[CC1Option]>,
598  HelpText<"Specify the default maximum struct packing alignment">;
599def fpascal_strings : Flag<"-fpascal-strings">, Group<f_Group>, Flags<[CC1Option]>,
600  HelpText<"Recognize and construct Pascal-style string literals">;
601def fpch_preprocess : Flag<"-fpch-preprocess">, Group<f_Group>;
602def fpic : Flag<"-fpic">, Group<f_Group>;
603def fno_pic : Flag<"-fno-pic">, Group<f_Group>;
604def fpie : Flag<"-fpie">, Group<f_Group>;
605def fno_pie : Flag<"-fno-pie">, Group<f_Group>;
606def fprofile_arcs : Flag<"-fprofile-arcs">, Group<f_Group>;
607def fprofile_generate : Flag<"-fprofile-generate">, Group<f_Group>;
608def framework : Separate<"-framework">, Flags<[LinkerInput]>;
609def frandom_seed_EQ : Joined<"-frandom-seed=">, Group<clang_ignored_f_Group>;
610def frtti : Flag<"-frtti">, Group<f_Group>;
611def fsched_interblock : Flag<"-fsched-interblock">, Group<clang_ignored_f_Group>;
612def fshort_enums : Flag<"-fshort-enums">, Group<f_Group>, Flags<[CC1Option]>,
613  HelpText<"Allocate to an enum type only as many bytes as it needs for the declared range of possible values">;
614def freorder_blocks : Flag<"-freorder-blocks">, Group<clang_ignored_f_Group>;
615def fshort_wchar : Flag<"-fshort-wchar">, Group<f_Group>, Flags<[CC1Option]>,
616  HelpText<"Force wchar_t to be a short unsigned int">;
617def fshow_overloads_EQ : Joined<"-fshow-overloads=">, Group<f_Group>, Flags<[CC1Option]>,
618  HelpText<"Which overload candidates to show when overload resolution fails: "
619           "best|all; defaults to all">;
620def fshow_column : Flag<"-fshow-column">, Group<f_Group>, Flags<[CC1Option]>;
621def fshow_source_location : Flag<"-fshow-source-location">, Group<f_Group>;
622def fspell_checking : Flag<"-fspell-checking">, Group<f_Group>;
623def fsigned_bitfields : Flag<"-fsigned-bitfields">, Group<f_Group>;
624def fsigned_char : Flag<"-fsigned-char">, Group<f_Group>;
625def fstack_protector_all : Flag<"-fstack-protector-all">, Group<f_Group>;
626def fstack_protector : Flag<"-fstack-protector">, Group<f_Group>;
627def fstrict_aliasing : Flag<"-fstrict-aliasing">, Group<f_Group>;
628def fstrict_enums : Flag<"-fstrict-enums">, Group<f_Group>, Flags<[CC1Option]>,
629  HelpText<"Enable optimizations based on the strict definition of an enum's "
630           "value range.">;
631def fstrict_overflow : Flag<"-fstrict-overflow">, Group<f_Group>;
632def fsyntax_only : Flag<"-fsyntax-only">, Flags<[DriverOption,CC1Option]>, Group<Action_Group>;
633def ftabstop_EQ : Joined<"-ftabstop=">, Group<f_Group>;
634def ftemplate_depth_EQ : Joined<"-ftemplate-depth=">, Group<f_Group>;
635def ftemplate_depth_ : Joined<"-ftemplate-depth-">, Group<f_Group>;
636def ftemplate_backtrace_limit_EQ : Joined<"-ftemplate-backtrace-limit=">,
637                                   Group<f_Group>;
638def ftest_coverage : Flag<"-ftest-coverage">, Group<f_Group>;
639def Wlarge_by_value_copy_def : Flag<"-Wlarge-by-value-copy">,
640  HelpText<"Warn if a function definition returns or accepts an object larger "
641           "in bytes that a given value">;
642def Wlarge_by_value_copy_EQ : Joined<"-Wlarge-by-value-copy=">, Flags<[CC1Option]>;
643
644// Just silence warnings about -Wlarger-than,  -Wframe-larger-than for now.
645def Wlarger_than : Separate<"-Wlarger-than">, Group<clang_ignored_f_Group>;
646def Wlarger_than_EQ : Joined<"-Wlarger-than=">, Alias<Wlarger_than>;
647def Wlarger_than_ : Joined<"-Wlarger-than-">, Alias<Wlarger_than>;
648def Wframe_larger_than : Separate<"-Wframe-larger-than">, Group<clang_ignored_f_Group>;
649def Wframe_larger_than_EQ : Joined<"-Wframe-larger-than=">, Alias<Wframe_larger_than>;
650
651def fterminated_vtables : Flag<"-fterminated-vtables">, Alias<fapple_kext>;
652def fthreadsafe_statics : Flag<"-fthreadsafe-statics">, Group<f_Group>;
653def ftime_report : Flag<"-ftime-report">, Group<f_Group>, Flags<[CC1Option]>;
654def ftlsmodel_EQ : Joined<"-ftls-model=">, Group<f_Group>, Flags<[CC1Option]>;
655def ftrapv : Flag<"-ftrapv">, Group<f_Group>, Flags<[CC1Option]>,
656  HelpText<"Trap on integer overflow">;
657def ftrapv_handler_EQ : Joined<"-ftrapv-handler=">, Group<f_Group>,
658  MetaVarName<"<function name>">,
659  HelpText<"Specify the function to be called on overflow.">;
660def ftrapv_handler : Separate<"-ftrapv-handler">, Group<f_Group>, Flags<[CC1Option]>;
661def ftrap_function_EQ : Joined<"-ftrap-function=">, Group<f_Group>, Flags<[CC1Option]>,
662  HelpText<"Issue call to specified function rather than a trap instruction">;
663def funit_at_a_time : Flag<"-funit-at-a-time">, Group<f_Group>;
664def funroll_loops : Flag<"-funroll-loops">, Group<f_Group>,
665  HelpText<"Turn on loop unroller">, Flags<[CC1Option]>;
666def funsigned_bitfields : Flag<"-funsigned-bitfields">, Group<f_Group>;
667def funsigned_char : Flag<"-funsigned-char">, Group<f_Group>;
668def funwind_tables : Flag<"-funwind-tables">, Group<f_Group>;
669def fuse_cxa_atexit : Flag<"-fuse-cxa-atexit">, Group<f_Group>;
670def fverbose_asm : Flag<"-fverbose-asm">, Group<f_Group>;
671def fvisibility_EQ : Joined<"-fvisibility=">, Group<f_Group>;
672def fvisibility_inlines_hidden : Flag<"-fvisibility-inlines-hidden">, Group<f_Group>,
673  HelpText<"Give inline C++ member functions default visibility by default">,
674  Flags<[CC1Option]>;
675def fwrapv : Flag<"-fwrapv">, Group<f_Group>, Flags<[CC1Option]>,
676  HelpText<"Treat signed integer overflow as two's complement">;
677def fwritable_strings : Flag<"-fwritable-strings">, Group<f_Group>, Flags<[CC1Option]>,
678  HelpText<"Store string literals as writable data">;
679def fzero_initialized_in_bss : Flag<"-fzero-initialized-in-bss">, Group<f_Group>;
680def ffunction_sections: Flag <"-ffunction-sections">, Group<f_Group>,
681  Flags<[CC1Option]>, HelpText<"Place each function in its own section (ELF Only)">;
682def fdata_sections : Flag <"-fdata-sections">, Group<f_Group>, Flags<[CC1Option]>,
683  HelpText<"Place each data in its own section (ELF Only)">;
684def f : Joined<"-f">, Group<f_Group>;
685def g_Flag : Flag<"-g">, Group<g_Group>,
686  HelpText<"Generate source level debug information">, Flags<[CC1Option]>;
687def gline_tables_only : Flag<"-gline-tables-only">, Group<g_Group>,
688  HelpText<"Emit debug line number tables only">, Flags<[CC1Option]>;
689def g0 : Flag<"-g0">, Group<g_Group>;
690def g1 : Flag<"-g1">, Group<g_Group>;
691def g2 : Flag<"-g2">, Group<g_Group>;
692def g3 : Flag<"-g3">, Group<g_Group>;
693def ggdb : Flag<"-ggdb">, Group<g_Group>;
694def ggdb0 : Flag<"-ggdb0">, Group<g_Group>;
695def ggdb1 : Flag<"-ggdb1">, Group<g_Group>;
696def ggdb2 : Flag<"-ggdb2">, Group<g_Group>;
697def ggdb3 : Flag<"-ggdb3">, Group<g_Group>;
698def gdwarf_2 : Flag<"-gdwarf-2">, Group<g_Group>;
699def gdwarf_3 : Flag<"-gdwarf-3">, Group<g_Group>;
700def gdwarf_4 : Flag<"-gdwarf-4">, Group<g_Group>;
701def gfull : Flag<"-gfull">, Group<g_Group>;
702def gused : Flag<"-gused">, Group<g_Group>;
703def gstabs : Joined<"-gstabs">, Group<g_Group>, Flags<[Unsupported]>;
704def gcoff : Joined<"-gcoff">, Group<g_Group>, Flags<[Unsupported]>;
705def gxcoff : Joined<"-gxcoff">, Group<g_Group>, Flags<[Unsupported]>;
706def gvms : Joined<"-gvms">, Group<g_Group>, Flags<[Unsupported]>;
707def gtoggle : Flag<"-gtoggle">, Group<g_flags_Group>, Flags<[Unsupported]>;
708def grecord_gcc_switches : Flag<"-grecord-gcc-switches">, Group<g_flags_Group>;
709def gno_record_gcc_switches : Flag<"-gno-record-gcc-switches">,
710  Group<g_flags_Group>;
711def gstrict_dwarf : Flag<"-gstrict-dwarf">, Group<g_flags_Group>;
712def gno_strict_dwarf : Flag<"-gno-strict-dwarf">, Group<g_flags_Group>;
713def headerpad__max__install__names : Joined<"-headerpad_max_install_names">;
714def help : Flag<"-help">, Flags<[CC1Option]>,
715  HelpText<"Display available options">;
716def index_header_map : Flag<"-index-header-map">, Flags<[CC1Option]>,
717  HelpText<"Make the next included directory (-I or -F) an indexer header map">;
718def idirafter : JoinedOrSeparate<"-idirafter">, Group<clang_i_Group>, Flags<[CC1Option]>,
719  HelpText<"Add directory to AFTER include search path">;
720def iframework : Joined<"-iframework">, Group<clang_i_Group>, Flags<[CC1Option]>,
721  HelpText<"Add directory to SYSTEM framework search path">;
722def imacros : JoinedOrSeparate<"-imacros">, Group<clang_i_Group>, Flags<[CC1Option]>,
723  HelpText<"Include macros from file before parsing">, MetaVarName<"<file>">;
724def image__base : Separate<"-image_base">;
725def include_ : JoinedOrSeparate<"-include">, Group<clang_i_Group>, EnumName<"include">,
726    MetaVarName<"<file>">, HelpText<"Include file before parsing">, Flags<[CC1Option]>;
727def include_pch : Separate<"-include-pch">, Group<clang_i_Group>, Flags<[CC1Option]>,
728  HelpText<"Include precompiled header file">, MetaVarName<"<file>">;
729def init : Separate<"-init">;
730def install__name : Separate<"-install_name">;
731def integrated_as : Flag<"-integrated-as">, Flags<[DriverOption]>;
732def iprefix : JoinedOrSeparate<"-iprefix">, Group<clang_i_Group>, Flags<[CC1Option]>,
733  HelpText<"Set the -iwithprefix/-iwithprefixbefore prefix">, MetaVarName<"<dir>">;
734def iquote : JoinedOrSeparate<"-iquote">, Group<clang_i_Group>, Flags<[CC1Option]>,
735  HelpText<"Add directory to QUOTE include search path">, MetaVarName<"<directory>">;
736def isysroot : JoinedOrSeparate<"-isysroot">, Group<clang_i_Group>, Flags<[CC1Option]>,
737  HelpText<"Set the system root directory (usually /)">, MetaVarName<"<dir>">;
738def isystem : JoinedOrSeparate<"-isystem">, Group<clang_i_Group>, Flags<[CC1Option]>,
739  HelpText<"Add directory to SYSTEM include search path">, MetaVarName<"<directory>">;
740def iwithprefixbefore : JoinedOrSeparate<"-iwithprefixbefore">, Group<clang_i_Group>,
741  HelpText<"Set directory to include search path with prefix">, MetaVarName<"<dir>">,
742  Flags<[CC1Option]>;
743def iwithprefix : JoinedOrSeparate<"-iwithprefix">, Group<clang_i_Group>, Flags<[CC1Option]>,
744  HelpText<"Set directory to SYSTEM include search path with prefix">, MetaVarName<"<dir>">;
745def iwithsysroot : JoinedOrSeparate<"-iwithsysroot">, Group<clang_i_Group>,
746  HelpText<"Add directory to SYSTEM include search path, "
747           "absolute paths are relative to -isysroot">, MetaVarName<"<directory>">,
748  Flags<[CC1Option]>;
749def i : Joined<"-i">, Group<i_Group>;
750def keep__private__externs : Flag<"-keep_private_externs">;
751def l : JoinedOrSeparate<"-l">, Flags<[LinkerInput, RenderJoined]>;
752def lazy__framework : Separate<"-lazy_framework">, Flags<[LinkerInput]>;
753def lazy__library : Separate<"-lazy_library">, Flags<[LinkerInput]>;
754def m32 : Flag<"-m32">, Group<m_Group>, Flags<[DriverOption]>;
755def mqdsp6_compat : Flag<"-mqdsp6-compat">, Group<m_Group>, Flags<[DriverOption,CC1Option]>,
756  HelpText<"Enable hexagon-qdsp6 backward compatibility">;
757def m3dnowa : Flag<"-m3dnowa">, Group<m_x86_Features_Group>;
758def m3dnow : Flag<"-m3dnow">, Group<m_x86_Features_Group>;
759def m64 : Flag<"-m64">, Group<m_Group>, Flags<[DriverOption]>;
760def mabi_EQ : Joined<"-mabi=">, Group<m_Group>;
761def march_EQ : Joined<"-march=">, Group<m_Group>;
762def maltivec : Flag<"-maltivec">, Alias<faltivec>;
763def mcmodel_EQ : Joined<"-mcmodel=">, Group<m_Group>;
764def mconstant_cfstrings : Flag<"-mconstant-cfstrings">, Group<clang_ignored_m_Group>;
765def mcpu_EQ : Joined<"-mcpu=">, Group<m_Group>;
766def mdynamic_no_pic : Joined<"-mdynamic-no-pic">, Group<m_Group>;
767def mfix_and_continue : Flag<"-mfix-and-continue">, Group<clang_ignored_m_Group>;
768def mfloat_abi_EQ : Joined<"-mfloat-abi=">, Group<m_Group>;
769def mfpmath_EQ : Joined<"-mfpmath=">, Group<m_Group>;
770def mfpu_EQ : Joined<"-mfpu=">, Group<m_Group>;
771def mglobal_merge : Flag<"-mglobal-merge">, Group<m_Group>;
772def mhard_float : Flag<"-mhard-float">, Group<m_Group>;
773def miphoneos_version_min_EQ : Joined<"-miphoneos-version-min=">, Group<m_Group>;
774def mios_version_min_EQ : Joined<"-mios-version-min=">, Alias<miphoneos_version_min_EQ>;
775def mios_simulator_version_min_EQ : Joined<"-mios-simulator-version-min=">, Group<m_Group>;
776def mkernel : Flag<"-mkernel">, Group<m_Group>;
777def mlinker_version_EQ : Joined<"-mlinker-version=">, Flags<[NoForward]>;
778def mllvm : Separate<"-mllvm">, Flags<[CC1Option]>,
779  HelpText<"Additional arguments to forward to LLVM's option processing">;
780def mmacosx_version_min_EQ : Joined<"-mmacosx-version-min=">, Group<m_Group>;
781def mms_bitfields : Flag<"-mms-bitfields">, Group<m_Group>, Flags<[CC1Option]>,
782  HelpText<"Set the default structure layout to be compatible with the Microsoft compiler standard.">;
783def mstackrealign : Flag<"-mstackrealign">, Group<m_Group>, Flags<[CC1Option]>,
784  HelpText<"Force realign the stack at entry to every function.">;
785def mstack_alignment : Joined<"-mstack-alignment=">, Group<m_Group>, Flags<[CC1Option]>,
786  HelpText<"Set the stack alignment">;
787def mmmx : Flag<"-mmmx">, Group<m_x86_Features_Group>;
788def mno_3dnowa : Flag<"-mno-3dnowa">, Group<m_x86_Features_Group>;
789def mno_3dnow : Flag<"-mno-3dnow">, Group<m_x86_Features_Group>;
790def mno_constant_cfstrings : Flag<"-mno-constant-cfstrings">, Group<m_Group>;
791def mno_global_merge : Flag<"-mno-global-merge">, Group<m_Group>, Flags<[CC1Option]>,
792  HelpText<"Disable merging of globals">;
793def mno_mmx : Flag<"-mno-mmx">, Group<m_x86_Features_Group>;
794def mno_pascal_strings : Flag<"-mno-pascal-strings">, Group<m_Group>;
795def mno_red_zone : Flag<"-mno-red-zone">, Group<m_Group>;
796def mno_relax_all : Flag<"-mno-relax-all">, Group<m_Group>;
797def mno_rtd: Flag<"-mno-rtd">, Group<m_Group>;
798def mno_soft_float : Flag<"-mno-soft-float">, Group<m_Group>;
799def mno_stackrealign : Flag<"-mno-stackrealign">, Group<m_Group>;
800def mno_sse2 : Flag<"-mno-sse2">, Group<m_x86_Features_Group>;
801def mno_sse3 : Flag<"-mno-sse3">, Group<m_x86_Features_Group>;
802def mno_sse4a : Flag<"-mno-sse4a">, Group<m_x86_Features_Group>;
803def mno_sse4 : Flag<"-mno-sse4">, Group<m_x86_Features_Group>;
804def mno_sse4_1 : Flag<"-mno-sse4.1">, Group<m_x86_Features_Group>;
805def mno_sse4_2 : Flag<"-mno-sse4.2">, Group<m_x86_Features_Group>;
806def mno_sse : Flag<"-mno-sse">, Group<m_x86_Features_Group>;
807def mno_ssse3 : Flag<"-mno-ssse3">, Group<m_x86_Features_Group>;
808def mno_aes : Flag<"-mno-aes">, Group<m_x86_Features_Group>;
809def mno_avx : Flag<"-mno-avx">, Group<m_x86_Features_Group>;
810def mno_avx2 : Flag<"-mno-avx2">, Group<m_x86_Features_Group>;
811def mno_pclmul : Flag<"-mno-pclmul">, Group<m_x86_Features_Group>;
812def mno_lzcnt : Flag<"-mno-lzcnt">, Group<m_x86_Features_Group>;
813def mno_rdrnd : Flag<"-mno-rdrnd">, Group<m_x86_Features_Group>;
814def mno_bmi : Flag<"-mno-bmi">, Group<m_x86_Features_Group>;
815def mno_bmi2 : Flag<"-mno-bmi2">, Group<m_x86_Features_Group>;
816def mno_popcnt : Flag<"-mno-popcnt">, Group<m_x86_Features_Group>;
817def mno_fma4 : Flag<"-mno-fma4">, Group<m_x86_Features_Group>;
818def mno_fma : Flag<"-mno-fma">, Group<m_x86_Features_Group>;
819def mno_xop : Flag<"-mno-xop">, Group<m_x86_Features_Group>;
820
821def mno_thumb : Flag<"-mno-thumb">, Group<m_Group>;
822def marm : Flag<"-marm">, Alias<mno_thumb>;
823
824def mno_warn_nonportable_cfstrings : Flag<"-mno-warn-nonportable-cfstrings">, Group<m_Group>;
825def mno_omit_leaf_frame_pointer : Flag<"-mno-omit-leaf-frame-pointer">, Group<f_Group>;
826def momit_leaf_frame_pointer : Flag<"-momit-leaf-frame-pointer">, Group<f_Group>,
827  HelpText<"Omit frame pointer setup for leaf functions.">, Flags<[CC1Option]>;
828def mpascal_strings : Flag<"-mpascal-strings">, Group<m_Group>;
829def mred_zone : Flag<"-mred-zone">, Group<m_Group>;
830def mregparm_EQ : Joined<"-mregparm=">, Group<m_Group>;
831def mrelax_all : Flag<"-mrelax-all">, Group<m_Group>, Flags<[CC1Option]>,
832  HelpText<"(integrated-as) Relax all machine instructions">;
833def mrtd : Flag<"-mrtd">, Group<m_Group>, Flags<[CC1Option]>,
834  HelpText<"Make StdCall calling convention the default">;
835def msmall_data_threshold_EQ : Joined <"-msmall-data-threshold=">, Group<m_Group>;
836def msoft_float : Flag<"-msoft-float">, Group<m_Group>, Flags<[CC1Option]>,
837  HelpText<"Use software floating point">;
838def mno_implicit_float : Flag<"-mno-implicit-float">, Group<m_Group>,
839  HelpText<"Don't generate implicit floating point instructions">;
840def msse2 : Flag<"-msse2">, Group<m_x86_Features_Group>;
841def msse3 : Flag<"-msse3">, Group<m_x86_Features_Group>;
842def msse4a : Flag<"-msse4a">, Group<m_x86_Features_Group>;
843def msse4 : Flag<"-msse4">, Group<m_x86_Features_Group>;
844def msse4_1 : Flag<"-msse4.1">, Group<m_x86_Features_Group>;
845def msse4_2 : Flag<"-msse4.2">, Group<m_x86_Features_Group>;
846def msse : Flag<"-msse">, Group<m_x86_Features_Group>;
847def mssse3 : Flag<"-mssse3">, Group<m_x86_Features_Group>;
848def maes : Flag<"-maes">, Group<m_x86_Features_Group>;
849def mavx : Flag<"-mavx">, Group<m_x86_Features_Group>;
850def mavx2 : Flag<"-mavx2">, Group<m_x86_Features_Group>;
851def mpclmul : Flag<"-mpclmul">, Group<m_x86_Features_Group>;
852def mlzcnt : Flag<"-mlzcnt">, Group<m_x86_Features_Group>;
853def mrdrnd : Flag<"-mrdrnd">, Group<m_x86_Features_Group>;
854def mbmi : Flag<"-mbmi">, Group<m_x86_Features_Group>;
855def mbmi2 : Flag<"-mbmi2">, Group<m_x86_Features_Group>;
856def mpopcnt : Flag<"-mpopcnt">, Group<m_x86_Features_Group>;
857def mfma4 : Flag<"-mfma4">, Group<m_x86_Features_Group>;
858def mfma : Flag<"-mfma">, Group<m_x86_Features_Group>;
859def mxop : Flag<"-mxop">, Group<m_x86_Features_Group>;
860def mips16 : Flag<"-mips16">, Group<m_Group>;
861def mno_mips16 : Flag<"-mno-mips16">, Group<m_Group>;
862def mdsp : Flag<"-mdsp">, Group<m_Group>;
863def mno_dsp : Flag<"-mno-dsp">, Group<m_Group>;
864def mdspr2 : Flag<"-mdspr2">, Group<m_Group>;
865def mno_dspr2 : Flag<"-mno-dspr2">, Group<m_Group>;
866def mthumb : Flag<"-mthumb">, Group<m_Group>;
867def mtune_EQ : Joined<"-mtune=">, Group<m_Group>;
868def multi__module : Flag<"-multi_module">;
869def multiply__defined__unused : Separate<"-multiply_defined_unused">;
870def multiply__defined : Separate<"-multiply_defined">;
871def mwarn_nonportable_cfstrings : Flag<"-mwarn-nonportable-cfstrings">, Group<m_Group>;
872def m_Separate : Separate<"-m">, Group<m_Group>;
873def m_Joined : Joined<"-m">, Group<m_Group>;
874def no_canonical_prefixes : Flag<"-no-canonical-prefixes">, Flags<[HelpHidden]>,
875  HelpText<"Use relative instead of canonical paths">;
876def no_cpp_precomp : Flag<"-no-cpp-precomp">, Group<clang_ignored_f_Group>;
877def no_integrated_as : Flag<"-no-integrated-as">, Flags<[DriverOption]>;
878def no_integrated_cpp : Flag<"-no-integrated-cpp">, Flags<[DriverOption]>;
879def no_pedantic : Flag<"-no-pedantic">, Group<pedantic_Group>;
880def no__dead__strip__inits__and__terms : Flag<"-no_dead_strip_inits_and_terms">;
881def nobuiltininc : Flag<"-nobuiltininc">, Flags<[CC1Option]>,
882  HelpText<"Disable builtin #include directories">;
883def nodefaultlibs : Flag<"-nodefaultlibs">;
884def nofixprebinding : Flag<"-nofixprebinding">;
885def nolibc : Flag<"-nolibc">;
886def nomultidefs : Flag<"-nomultidefs">;
887def noprebind : Flag<"-noprebind">;
888def noseglinkedit : Flag<"-noseglinkedit">;
889def nostartfiles : Flag<"-nostartfiles">;
890def nostdinc : Flag<"-nostdinc">;
891def nostdlibinc : Flag<"-nostdlibinc">;
892def nostdincxx : Flag<"-nostdinc++">, Flags<[CC1Option]>,
893  HelpText<"Disable standard #include directories for the C++ standard library">;
894def nostdlib : Flag<"-nostdlib">;
895def object : Flag<"-object">;
896def o : JoinedOrSeparate<"-o">, Flags<[DriverOption, RenderAsInput, CC1Option]>,
897  HelpText<"Write output to <file>">, MetaVarName<"<file>">;
898def pagezero__size : JoinedOrSeparate<"-pagezero_size">;
899def pass_exit_codes : Flag<"-pass-exit-codes">, Flags<[Unsupported]>;
900def pedantic_errors : Flag<"-pedantic-errors">, Group<pedantic_Group>, Flags<[CC1Option]>;
901def pedantic : Flag<"-pedantic">, Group<pedantic_Group>, Flags<[CC1Option]>;
902def pg : Flag<"-pg">, HelpText<"Enable mcount instrumentation">, Flags<[CC1Option]>;
903def pipe : Flag<"-pipe">,
904  HelpText<"Use pipes between commands, when possible">;
905def prebind__all__twolevel__modules : Flag<"-prebind_all_twolevel_modules">;
906def prebind : Flag<"-prebind">;
907def preload : Flag<"-preload">;
908def print_file_name_EQ : Joined<"-print-file-name=">,
909  HelpText<"Print the full library path of <file>">, MetaVarName<"<file>">;
910def print_ivar_layout : Flag<"-print-ivar-layout">, Flags<[CC1Option]>,
911  HelpText<"Enable Objective-C Ivar layout bitmap print trace">;
912def print_libgcc_file_name : Flag<"-print-libgcc-file-name">,
913  HelpText<"Print the library path for \"libgcc.a\"">;
914def print_multi_directory : Flag<"-print-multi-directory">;
915def print_multi_lib : Flag<"-print-multi-lib">;
916def print_multi_os_directory : Flag<"-print-multi-os-directory">;
917def print_prog_name_EQ : Joined<"-print-prog-name=">,
918  HelpText<"Print the full program path of <name>">, MetaVarName<"<name>">;
919def print_search_dirs : Flag<"-print-search-dirs">,
920  HelpText<"Print the paths used for finding libraries and programs">;
921def private__bundle : Flag<"-private_bundle">;
922def pthreads : Flag<"-pthreads">;
923def pthread : Flag<"-pthread">, Flags<[CC1Option]>,
924  HelpText<"Support POSIX threads in generated code">;
925def p : Flag<"-p">;
926def pie : Flag<"-pie">;
927def read__only__relocs : Separate<"-read_only_relocs">;
928def remap : Flag<"-remap">;
929def rewrite_objc : Flag<"-rewrite-objc">, Flags<[DriverOption,CC1Option]>,
930  HelpText<"Rewrite Objective-C source to C++">, Group<Action_Group>;
931def rewrite_legacy_objc : Flag<"-rewrite-legacy-objc">, Flags<[DriverOption]>,
932  HelpText<"Rewrite Legacy Objective-C source to C++">;
933def rdynamic : Flag<"-rdynamic">;
934def rpath : Separate<"-rpath">, Flags<[LinkerInput]>;
935def rtlib_EQ : Joined<"-rtlib=">;
936def r : Flag<"-r">;
937def save_temps : Flag<"-save-temps">, Flags<[DriverOption]>,
938  HelpText<"Save intermediate compilation results">;
939def sectalign : MultiArg<"-sectalign", 3>;
940def sectcreate : MultiArg<"-sectcreate", 3>;
941def sectobjectsymbols : MultiArg<"-sectobjectsymbols", 2>;
942def sectorder : MultiArg<"-sectorder", 3>;
943def seg1addr : JoinedOrSeparate<"-seg1addr">;
944def seg__addr__table__filename : Separate<"-seg_addr_table_filename">;
945def seg__addr__table : Separate<"-seg_addr_table">;
946def segaddr : MultiArg<"-segaddr", 2>;
947def segcreate : MultiArg<"-segcreate", 3>;
948def seglinkedit : Flag<"-seglinkedit">;
949def segprot : MultiArg<"-segprot", 3>;
950def segs__read__only__addr : Separate<"-segs_read_only_addr">;
951def segs__read__write__addr : Separate<"-segs_read_write_addr">;
952def segs__read__ : Joined<"-segs_read_">;
953def shared_libgcc : Flag<"-shared-libgcc">;
954def shared : Flag<"-shared">;
955def single__module : Flag<"-single_module">;
956def specs_EQ : Joined<"-specs=">;
957def specs : Separate<"-specs">, Flags<[Unsupported]>;
958def static_libgcc : Flag<"-static-libgcc">;
959def static_libstdcxx : Flag<"-static-libstdc++">;
960def static : Flag<"-static">, Flags<[NoArgumentUnused]>;
961def std_default_EQ : Joined<"-std-default=">;
962def std_EQ : Joined<"-std=">, Flags<[CC1Option]>, Group<L_Group>,
963  HelpText<"Language standard to compile for">;
964def stdlib_EQ : Joined<"-stdlib=">, Flags<[CC1Option]>,
965  HelpText<"C++ standard library to use">;
966def sub__library : JoinedOrSeparate<"-sub_library">;
967def sub__umbrella : JoinedOrSeparate<"-sub_umbrella">;
968def s : Flag<"-s">;
969def target : Separate<"-target">, Flags<[DriverOption]>,
970  HelpText<"Generate code for the given target">;
971def gcc_toolchain : Separate<"-gcc-toolchain">, Flags<[DriverOption]>,
972  HelpText<"Use the gcc toolchain at the given directory">;
973// We should deprecate the use of -ccc-host-triple, and then remove.
974def ccc_host_triple : Separate<"-ccc-host-triple">, Alias<target>;
975def time : Flag<"-time">,
976  HelpText<"Time individual commands">;
977def traditional_cpp : Flag<"-traditional-cpp">, Flags<[CC1Option]>,
978  HelpText<"Enable some traditional CPP emulation">;
979def traditional : Flag<"-traditional">;
980def trigraphs : Flag<"-trigraphs">, Flags<[CC1Option]>,
981  HelpText<"Process trigraph sequences">;
982def twolevel__namespace__hints : Flag<"-twolevel_namespace_hints">;
983def twolevel__namespace : Flag<"-twolevel_namespace">;
984def t : Flag<"-t">;
985def umbrella : Separate<"-umbrella">;
986def undefined : JoinedOrSeparate<"-undefined">, Group<u_Group>;
987def undef : Flag<"-undef">, Group<u_Group>, Flags<[CC1Option]>,
988  HelpText<"undef all system defines">;
989def unexported__symbols__list : Separate<"-unexported_symbols_list">;
990def u : JoinedOrSeparate<"-u">, Group<u_Group>;
991def use_gold_plugin : Flag<"-use-gold-plugin">;
992def v : Flag<"-v">, Flags<[CC1Option]>,
993  HelpText<"Show commands to run and use verbose output">;
994def verify : Flag<"-verify">, Flags<[DriverOption,CC1Option]>,
995  HelpText<"Verify output using a verifier.">;
996def weak_l : Joined<"-weak-l">, Flags<[LinkerInput]>;
997def weak__framework : Separate<"-weak_framework">, Flags<[LinkerInput]>;
998def weak__library : Separate<"-weak_library">, Flags<[LinkerInput]>;
999def weak__reference__mismatches : Separate<"-weak_reference_mismatches">;
1000def whatsloaded : Flag<"-whatsloaded">;
1001def whyload : Flag<"-whyload">;
1002def w : Flag<"-w">, HelpText<"Suppress all warnings.">, Flags<[CC1Option]>;
1003def x : JoinedOrSeparate<"-x">, Flags<[DriverOption,CC1Option]>,
1004  HelpText<"Treat subsequent input files as having type <language>">,
1005  MetaVarName<"<language>">;
1006def y : Joined<"-y">;
1007
1008def working_directory : JoinedOrSeparate<"-working-directory">, Flags<[CC1Option]>,
1009  HelpText<"Resolve file paths relative to the specified directory">;
1010def working_directory_EQ : Joined<"-working-directory=">, Flags<[CC1Option]>,
1011  Alias<working_directory>;
1012
1013// Double dash options, which are usually an alias for one of the previous
1014// options.
1015
1016def _CLASSPATH_EQ : Joined<"--CLASSPATH=">, Alias<fclasspath_EQ>;
1017def _CLASSPATH : Separate<"--CLASSPATH">, Alias<fclasspath_EQ>;
1018def _all_warnings : Flag<"--all-warnings">, Alias<Wall>;
1019def _analyze_auto : Flag<"--analyze-auto">, Flags<[DriverOption]>;
1020def _analyzer_no_default_checks : Flag<"--analyzer-no-default-checks">, Flags<[DriverOption]>;
1021def _analyzer_output : JoinedOrSeparate<"--analyzer-output">, Flags<[DriverOption]>;
1022def _analyze : Flag<"--analyze">, Flags<[DriverOption]>,
1023  HelpText<"Run the static analyzer">;
1024def _ansi : Flag<"--ansi">, Alias<ansi>;
1025def _assemble : Flag<"--assemble">, Alias<S>;
1026def _assert_EQ : Joined<"--assert=">, Alias<A>;
1027def _assert : Separate<"--assert">, Alias<A>;
1028def _bootclasspath_EQ : Joined<"--bootclasspath=">, Alias<fbootclasspath_EQ>;
1029def _bootclasspath : Separate<"--bootclasspath">, Alias<fbootclasspath_EQ>;
1030def _classpath_EQ : Joined<"--classpath=">, Alias<fclasspath_EQ>;
1031def _classpath : Separate<"--classpath">, Alias<fclasspath_EQ>;
1032def _combine : Flag<"--combine">, Alias<combine>;
1033def _comments_in_macros : Flag<"--comments-in-macros">, Alias<CC>;
1034def _comments : Flag<"--comments">, Alias<C>;
1035def _compile : Flag<"--compile">, Alias<c>;
1036def _constant_cfstrings : Flag<"--constant-cfstrings">;
1037def _coverage : Flag<"--coverage">, Alias<coverage>;
1038def _debug_EQ : Joined<"--debug=">, Alias<g_Flag>;
1039def _debug : Flag<"--debug">, Alias<g_Flag>;
1040def _define_macro_EQ : Joined<"--define-macro=">, Alias<D>;
1041def _define_macro : Separate<"--define-macro">, Alias<D>;
1042def _dependencies : Flag<"--dependencies">, Alias<M>;
1043def _encoding_EQ : Joined<"--encoding=">, Alias<fencoding_EQ>;
1044def _encoding : Separate<"--encoding">, Alias<fencoding_EQ>;
1045def _entry : Flag<"--entry">, Alias<e>;
1046def _extdirs_EQ : Joined<"--extdirs=">, Alias<fextdirs_EQ>;
1047def _extdirs : Separate<"--extdirs">, Alias<fextdirs_EQ>;
1048def _extra_warnings : Flag<"--extra-warnings">, Alias<W_Joined>;
1049def _for_linker_EQ : Joined<"--for-linker=">, Alias<Xlinker>;
1050def _for_linker : Separate<"--for-linker">, Alias<Xlinker>;
1051def _force_link_EQ : Joined<"--force-link=">, Alias<u>;
1052def _force_link : Separate<"--force-link">, Alias<u>;
1053def _help_hidden : Flag<"--help-hidden">;
1054def _help : Flag<"--help">, Alias<help>;
1055def _imacros_EQ : Joined<"--imacros=">, Alias<imacros>;
1056def _imacros : Separate<"--imacros">, Alias<imacros>;
1057def _include_barrier : Flag<"--include-barrier">, Alias<I_>;
1058def _include_directory_after_EQ : Joined<"--include-directory-after=">, Alias<idirafter>;
1059def _include_directory_after : Separate<"--include-directory-after">, Alias<idirafter>;
1060def _include_directory_EQ : Joined<"--include-directory=">, Alias<I>;
1061def _include_directory : Separate<"--include-directory">, Alias<I>;
1062def _include_prefix_EQ : Joined<"--include-prefix=">, Alias<iprefix>;
1063def _include_prefix : Separate<"--include-prefix">, Alias<iprefix>;
1064def _include_with_prefix_after_EQ : Joined<"--include-with-prefix-after=">, Alias<iwithprefix>;
1065def _include_with_prefix_after : Separate<"--include-with-prefix-after">, Alias<iwithprefix>;
1066def _include_with_prefix_before_EQ : Joined<"--include-with-prefix-before=">, Alias<iwithprefixbefore>;
1067def _include_with_prefix_before : Separate<"--include-with-prefix-before">, Alias<iwithprefixbefore>;
1068def _include_with_prefix_EQ : Joined<"--include-with-prefix=">, Alias<iwithprefix>;
1069def _include_with_prefix : Separate<"--include-with-prefix">, Alias<iwithprefix>;
1070def _include_EQ : Joined<"--include=">, Alias<include_>;
1071def _include : Separate<"--include">, Alias<include_>;
1072def _language_EQ : Joined<"--language=">, Alias<x>;
1073def _language : Separate<"--language">, Alias<x>;
1074def _library_directory_EQ : Joined<"--library-directory=">, Alias<L>;
1075def _library_directory : Separate<"--library-directory">, Alias<L>;
1076def _machine__EQ : Joined<"--machine-=">, Alias<m_Joined>;
1077def _machine_ : Joined<"--machine-">, Alias<m_Joined>;
1078def _machine_EQ : Joined<"--machine=">, Alias<m_Joined>;
1079def _machine : Separate<"--machine">, Alias<m_Joined>;
1080def _no_integrated_cpp : Flag<"--no-integrated-cpp">, Alias<no_integrated_cpp>;
1081def _no_line_commands : Flag<"--no-line-commands">, Alias<P>;
1082def _no_pedantic : Flag<"--no-pedantic">, Alias<no_pedantic>;
1083def _no_standard_includes : Flag<"--no-standard-includes">, Alias<nostdinc>;
1084def _no_standard_libraries : Flag<"--no-standard-libraries">, Alias<nostdlib>;
1085def _no_undefined : Flag<"--no-undefined">, Flags<[LinkerInput]>;
1086def _no_warnings : Flag<"--no-warnings">, Alias<w>;
1087def _optimize_EQ : Joined<"--optimize=">, Alias<O>;
1088def _optimize : Flag<"--optimize">, Alias<O>;
1089def _output_class_directory_EQ : Joined<"--output-class-directory=">, Alias<foutput_class_dir_EQ>;
1090def _output_class_directory : Separate<"--output-class-directory">, Alias<foutput_class_dir_EQ>;
1091def _output_EQ : Joined<"--output=">, Alias<o>;
1092def _output : Separate<"--output">, Alias<o>;
1093def _param : Separate<"--param">;
1094def _param_EQ : Joined<"--param=">, Alias<_param>;
1095def _pass_exit_codes : Flag<"--pass-exit-codes">, Alias<pass_exit_codes>;
1096def _pedantic_errors : Flag<"--pedantic-errors">, Alias<pedantic_errors>;
1097def _pedantic : Flag<"--pedantic">, Alias<pedantic>;
1098def _pipe : Flag<"--pipe">, Alias<pipe>;
1099def _prefix_EQ : Joined<"--prefix=">, Alias<B>;
1100def _prefix : Separate<"--prefix">, Alias<B>;
1101def _preprocess : Flag<"--preprocess">, Alias<E>;
1102def _print_diagnostic_categories : Flag<"--print-diagnostic-categories">;
1103def _print_file_name_EQ : Joined<"--print-file-name=">, Alias<print_file_name_EQ>;
1104def _print_file_name : Separate<"--print-file-name">, Alias<print_file_name_EQ>;
1105def _print_libgcc_file_name : Flag<"--print-libgcc-file-name">, Alias<print_libgcc_file_name>;
1106def _print_missing_file_dependencies : Flag<"--print-missing-file-dependencies">, Alias<MG>;
1107def _print_multi_directory : Flag<"--print-multi-directory">, Alias<print_multi_directory>;
1108def _print_multi_lib : Flag<"--print-multi-lib">, Alias<print_multi_lib>;
1109def _print_multi_os_directory : Flag<"--print-multi-os-directory">, Alias<print_multi_os_directory>;
1110def _print_prog_name_EQ : Joined<"--print-prog-name=">, Alias<print_prog_name_EQ>;
1111def _print_prog_name : Separate<"--print-prog-name">, Alias<print_prog_name_EQ>;
1112def _print_search_dirs : Flag<"--print-search-dirs">, Alias<print_search_dirs>;
1113def _profile_blocks : Flag<"--profile-blocks">, Alias<a>;
1114def _profile : Flag<"--profile">, Alias<p>;
1115def _relocatable_pch : Flag<"--relocatable-pch">,
1116  HelpText<"Build a relocatable precompiled header">;
1117def _resource_EQ : Joined<"--resource=">, Alias<fcompile_resource_EQ>;
1118def _resource : Separate<"--resource">, Alias<fcompile_resource_EQ>;
1119def _rtlib_EQ : Joined<"--rtlib=">, Alias<rtlib_EQ>;
1120def _rtlib : Separate<"--rtlib">, Alias<rtlib_EQ>;
1121def _save_temps : Flag<"--save-temps">, Alias<save_temps>;
1122def _serialize_diags : Separate<"--serialize-diagnostics">, Flags<[DriverOption]>,
1123  HelpText<"Serialize compiler diagnostics to a file">;
1124def _shared : Flag<"--shared">, Alias<shared>;
1125def _signed_char : Flag<"--signed-char">, Alias<fsigned_char>;
1126def _specs_EQ : Joined<"--specs=">, Alias<specs_EQ>;
1127def _specs : Separate<"--specs">, Alias<specs_EQ>;
1128def _static : Flag<"--static">, Alias<static>;
1129def _std_EQ : Joined<"--std=">, Alias<std_EQ>;
1130def _std : Separate<"--std">, Alias<std_EQ>;
1131def _stdlib_EQ : Joined<"--stdlib=">, Alias<stdlib_EQ>;
1132def _stdlib : Separate<"--stdlib">, Alias<stdlib_EQ>;
1133def _sysroot_EQ : Joined<"--sysroot=">;
1134def _sysroot : Separate<"--sysroot">, Alias<_sysroot_EQ>;
1135def _target_help : Flag<"--target-help">;
1136def _trace_includes : Flag<"--trace-includes">, Alias<H>;
1137def _traditional_cpp : Flag<"--traditional-cpp">, Alias<traditional_cpp>;
1138def _traditional : Flag<"--traditional">, Alias<traditional>;
1139def _trigraphs : Flag<"--trigraphs">, Alias<trigraphs>;
1140def _undefine_macro_EQ : Joined<"--undefine-macro=">, Alias<U>;
1141def _undefine_macro : Separate<"--undefine-macro">, Alias<U>;
1142def _unsigned_char : Flag<"--unsigned-char">, Alias<funsigned_char>;
1143def _user_dependencies : Flag<"--user-dependencies">, Alias<MM>;
1144def _verbose : Flag<"--verbose">, Alias<v>;
1145def _version : Flag<"--version">,  Flags<[CC1Option]>;
1146def _warn__EQ : Joined<"--warn-=">, Alias<W_Joined>;
1147def _warn_ : Joined<"--warn-">, Alias<W_Joined>;
1148def _write_dependencies : Flag<"--write-dependencies">, Alias<MD>;
1149def _write_user_dependencies : Flag<"--write-user-dependencies">, Alias<MMD>;
1150def _ : Joined<"--">, Flags<[Unsupported]>;
1151def mieee_rnd_near : Flag<"-mieee-rnd-near">, Group<m_hexagon_Features_Group>;
1152def serialize_diags : Separate<"-serialize-diagnostics">, Alias<_serialize_diags>;
1153
1154// Special internal option to handle -Xlinker --no-demangle.
1155def Z_Xlinker__no_demangle : Flag<"-Z-Xlinker-no-demangle">,
1156    Flags<[Unsupported, NoArgumentUnused]>;
1157
1158// Special internal option to allow forwarding arbitrary arguments to linker.
1159def Zlinker_input : Separate<"-Zlinker-input">,
1160    Flags<[Unsupported, NoArgumentUnused]>;
1161
1162// Reserved library options.
1163def Z_reserved_lib_stdcxx : Flag<"-Z-reserved-lib-stdc++">,
1164    Flags<[LinkerInput, NoArgumentUnused, Unsupported]>, Group<reserved_lib_Group>;
1165def Z_reserved_lib_cckext : Flag<"-Z-reserved-lib-cckext">,
1166    Flags<[LinkerInput, NoArgumentUnused, Unsupported]>, Group<reserved_lib_Group>;
1167
1168include "CC1Options.td"
1169