diff options
author | Joseph Myers <joseph@codesourcery.com> | 2010-11-26 23:18:28 +0000 |
---|---|---|
committer | Joseph Myers <jsm28@gcc.gnu.org> | 2010-11-26 23:18:28 +0000 |
commit | e6d4b9841c35629de91c36ba40ed247fef749037 (patch) | |
tree | 36e9808ac190cda7d402aca282c7bbe11cbf8b71 /gcc/common.opt | |
parent | 8a1ffe230e5f07f6eef4bd30088f4245783109ec (diff) | |
download | gcc-e6d4b9841c35629de91c36ba40ed247fef749037.zip gcc-e6d4b9841c35629de91c36ba40ed247fef749037.tar.gz gcc-e6d4b9841c35629de91c36ba40ed247fef749037.tar.bz2 |
options.texi (Enum, EnumValue): Document new record types.
* doc/options.texi (Enum, EnumValue): Document new record types.
(Enum): Document new option flag.
* opt-functions.awk
* optc-gen.awk: Handle enumerated option arguments.
* opth-gen.awk: Handle enumerated option arguments.
* opts-common.c (enum_arg_ok_for_language, enum_arg_to_value,
enum_value_to_arg): New.
(decode_cmdline_option): Handle enumerated arguments.
(read_cmdline_option): Handle CL_ERR_ENUM_ARG.
(set_option, option_enabled, get_option_state): Handle CLVC_ENUM.
* opts.c (print_filtered_help, print_specific_help): Take
lang_mask arguments.
(print_filtered_help): Handle printing values of enumerated
options. Print possible arguments for enumerated options.
(print_specific_help): Update call to print_filtered_help.
(common_handle_option): Update calls to print_specific_help. Use
value rather than arg for OPT_fdiagnostics_show_location_. Don't
handle OPT_ffp_contract_, OPT_fexcess_precision_,
OPT_fvisibility_, OPT_ftls_model_, OPT_fira_algorithm_ or
OPT_fira_region_ here.
* opts.h (enum cl_var_type): Add CLVC_ENUM.
(struct cl_option): Add var_enum.
(CL_ENUM_CANONICAL, CL_ENUM_DRIVER_ONLY, struct cl_enum_arg,
struct cl_enum, cl_enums, cl_enums_count): New.
(CL_ERR_ENUM_ARG): Define.
(CL_ERR_NEGATIVE): Update value.
(enum_value_to_arg): Declare.
* common.opt (flag_ira_algorithm, flag_ira_region,
flag_fp_contract_mode, flag_excess_precision_cmdline,
default_visibility, flag_tls_default): Remove Variable entries.
(help_enum_printed): New Variable.
(fdiagnostics-show-location=): Use Enum. Add associated
SourceInclude, Enum and EnumValue entries.
(fexcess-precision=, ffp-contract=, fira-algorithm=, fira-region=,
ftls-model=, fvisibility=): Use Enum, Var and Init. Add
associated Enum and EnumValue entries.
po:
* exgettext: Handle UnknownError.
From-SVN: r167190
Diffstat (limited to 'gcc/common.opt')
-rw-r--r-- | gcc/common.opt | 131 |
1 files changed, 98 insertions, 33 deletions
diff --git a/gcc/common.opt b/gcc/common.opt index f4523db..57f5b0a 100644 --- a/gcc/common.opt +++ b/gcc/common.opt @@ -42,15 +42,6 @@ int flag_complex_method = 1 Variable int flag_evaluation_order = 0 -; Set the default region and algorithm for the integrated register -; allocator. - -Variable -enum ira_algorithm flag_ira_algorithm = IRA_ALGORITHM_CB - -Variable -enum ira_region flag_ira_region = IRA_REGION_MIXED - ; Language specific warning pass for unused results. Variable bool flag_warn_unused_result = false @@ -58,15 +49,6 @@ bool flag_warn_unused_result = false Variable int *param_values -; Floating-point contraction mode, fast by default. -Variable -enum fp_contract_mode flag_fp_contract_mode = FP_CONTRACT_FAST - -; The excess precision specified on the command line, or defaulted by -; the front end. -Variable -enum excess_precision flag_excess_precision_cmdline = EXCESS_PRECISION_DEFAULT - ; Nonzero if we should write GIMPLE bytecode for link-time optimization. Variable int flag_generate_lto @@ -97,14 +79,6 @@ int flag_gen_aux_info = 0 Variable int flag_shlib -; The default visibility for all symbols (unless overridden). -Variable -enum symbol_visibility default_visibility = VISIBILITY_DEFAULT - -; Set to the default thread-local storage (tls) model to use. -Variable -enum tls_model flag_tls_default = TLS_MODEL_GLOBAL_DYNAMIC - ; These two are really VEC(char_p,heap) *. Variable @@ -187,6 +161,12 @@ enum graph_dump_types graph_dump_format = no_graph Variable char *help_printed +; Which enums have been printed by --help. 0 = not printed, no +; relevant options seen, 1 = relevant option seen, not yet printed, 2 +; = printed. +Variable +char *help_enum_printed + ; The number of columns for --help output. Variable unsigned int help_columns @@ -897,9 +877,22 @@ Common Report Var(flag_delete_null_pointer_checks) Init(1) Optimization Delete useless null pointer checks fdiagnostics-show-location= -Common Joined RejectNegative +Common Joined RejectNegative Enum(diagnostic_prefixing_rule) -fdiagnostics-show-location=[once|every-line] How often to emit source location at the beginning of line-wrapped diagnostics +; Required for these enum values. +SourceInclude +pretty-print.h + +Enum +Name(diagnostic_prefixing_rule) Type(int) + +EnumValue +Enum(diagnostic_prefixing_rule) String(once) Value(DIAGNOSTICS_SHOW_PREFIX_ONCE) + +EnumValue +Enum(diagnostic_prefixing_rule) String(every-line) Value(DIAGNOSTICS_SHOW_PREFIX_EVERY_LINE) + fdiagnostics-show-option Common Var(flag_diagnostics_show_option) Init(1) Amend appropriate diagnostic messages with the command line option that controls them @@ -972,9 +965,18 @@ Common Report Var(flag_expensive_optimizations) Optimization Perform a number of minor, expensive optimizations fexcess-precision= -Common Joined RejectNegative +Common Joined RejectNegative Enum(excess_precision) Var(flag_excess_precision_cmdline) Init(EXCESS_PRECISION_DEFAULT) -fexcess-precision=[fast|standard] Specify handling of excess floating-point precision +Enum +Name(excess_precision) Type(enum excess_precision) UnknownError(unknown excess precision style %qs) + +EnumValue +Enum(excess_precision) String(fast) Value(EXCESS_PRECISION_FAST) + +EnumValue +Enum(excess_precision) String(standard) Value(EXCESS_PRECISION_STANDARD) + ffast-math Common @@ -999,9 +1001,22 @@ Common Report Var(flag_forward_propagate) Optimization Perform a forward propagation pass on RTL ffp-contract= -Common Joined RejectNegative +Common Joined RejectNegative Enum(fp_contract_mode) Var(flag_fp_contract_mode) Init(FP_CONTRACT_FAST) -ffp-contract=[off|on|fast] Perform floating-point expression contraction. +Enum +Name(fp_contract_mode) Type(enum fp_contract_mode) UnknownError(unknown floating point contraction style %qs) + +EnumValue +Enum(fp_contract_mode) String(off) Value(FP_CONTRACT_OFF) + +; Not implemented, fall back to conservative FP_CONTRACT_OFF. +EnumValue +Enum(fp_contract_mode) String(on) Value(FP_CONTRACT_OFF) + +EnumValue +Enum(fp_contract_mode) String(fast) Value(FP_CONTRACT_FAST) + ; Nonzero means don't put addresses of constant functions in registers. ; Used for compiling the Unix kernel, where strange substitutions are ; done on the assembly output. @@ -1183,13 +1198,34 @@ Perform structure layout optimizations based on profiling information. fira-algorithm= -Common Joined RejectNegative +Common Joined RejectNegative Enum(ira_algorithm) Var(flag_ira_algorithm) Init(IRA_ALGORITHM_CB) -fira-algorithm=[CB|priority] Set the used IRA algorithm +Enum +Name(ira_algorithm) Type(enum ira_algorithm) UnknownError(unknown IRA algorithm %qs) + +EnumValue +Enum(ira_algorithm) String(CB) Value(IRA_ALGORITHM_CB) + +EnumValue +Enum(ira_algorithm) String(priority) Value(IRA_ALGORITHM_PRIORITY) + fira-region= -Common Joined RejectNegative +Common Joined RejectNegative Enum(ira_region) Var(flag_ira_region) Init(IRA_REGION_MIXED) -fira-region=[one|all|mixed] Set regions for IRA +Enum +Name(ira_region) Type(enum ira_region) UnknownError(unknown IRA region %qs) + +EnumValue +Enum(ira_region) String(one) Value(IRA_REGION_ONE) + +EnumValue +Enum(ira_region) String(all) Value(IRA_REGION_ALL) + +EnumValue +Enum(ira_region) String(mixed) Value(IRA_REGION_MIXED) + fira-loop-pressure Common Report Var(flag_ira_loop_pressure) Use IRA based register pressure calculation @@ -1718,9 +1754,24 @@ Common Report Var(time_report) Report the time taken by each compiler pass ftls-model= -Common Joined RejectNegative +Common Joined RejectNegative Enum(tls_model) Var(flag_tls_default) Init(TLS_MODEL_GLOBAL_DYNAMIC) -ftls-model=[global-dynamic|local-dynamic|initial-exec|local-exec] Set the default thread-local storage code generation model +Enum +Name(tls_model) Type(enum tls_model) UnknownError(unknown TLS model %qs) + +EnumValue +Enum(tls_model) String(global-dynamic) Value(TLS_MODEL_GLOBAL_DYNAMIC) + +EnumValue +Enum(tls_model) String(local-dynamic) Value(TLS_MODEL_LOCAL_DYNAMIC) + +EnumValue +Enum(tls_model) String(initial-exec) Value(TLS_MODEL_INITIAL_EXEC) + +EnumValue +Enum(tls_model) String(local-exec) Value(TLS_MODEL_LOCAL_EXEC) + ftoplevel-reorder Common Report Var(flag_toplevel_reorder) Init(2) Optimization Reorder top level functions, variables, and asms @@ -1973,9 +2024,23 @@ Common Report Var(flag_verbose_asm) Add extra commentary to assembler output fvisibility= -Common Joined RejectNegative +Common Joined RejectNegative Enum(symbol_visibility) Var(default_visibility) Init(VISIBILITY_DEFAULT) -fvisibility=[default|internal|hidden|protected] Set the default symbol visibility +Enum +Name(symbol_visibility) Type(enum symbol_visibility) UnknownError(unrecognized visibility value %qs) + +EnumValue +Enum(symbol_visibility) String(default) Value(VISIBILITY_DEFAULT) + +EnumValue +Enum(symbol_visibility) String(internal) Value(VISIBILITY_INTERNAL) + +EnumValue +Enum(symbol_visibility) String(hidden) Value(VISIBILITY_HIDDEN) + +EnumValue +Enum(symbol_visibility) String(protected) Value(VISIBILITY_PROTECTED) fvpt Common Report Var(flag_value_profile_transformations) Optimization |