annotate gcc/common/common-target.def @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children 1830386684a0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* Target hook definitions for common hooks.
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
2 Copyright (C) 2011-2018 Free Software Foundation, Inc.
111
kono
parents:
diff changeset
3
kono
parents:
diff changeset
4 This program is free software; you can redistribute it and/or modify it
kono
parents:
diff changeset
5 under the terms of the GNU General Public License as published by the
kono
parents:
diff changeset
6 Free Software Foundation; either version 3, or (at your option) any
kono
parents:
diff changeset
7 later version.
kono
parents:
diff changeset
8
kono
parents:
diff changeset
9 This program is distributed in the hope that it will be useful,
kono
parents:
diff changeset
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
kono
parents:
diff changeset
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
kono
parents:
diff changeset
12 GNU General Public License for more details.
kono
parents:
diff changeset
13
kono
parents:
diff changeset
14 You should have received a copy of the GNU General Public License
kono
parents:
diff changeset
15 along with this program; see the file COPYING3. If not see
kono
parents:
diff changeset
16 <http://www.gnu.org/licenses/>. */
kono
parents:
diff changeset
17
kono
parents:
diff changeset
18 /* See target-hooks-macros.h for details of macros that should be
kono
parents:
diff changeset
19 provided by the including file, and how to use them here. */
kono
parents:
diff changeset
20 #include "target-hooks-macros.h"
kono
parents:
diff changeset
21
kono
parents:
diff changeset
22 #undef HOOK_TYPE
kono
parents:
diff changeset
23 #define HOOK_TYPE "Common Target Hook"
kono
parents:
diff changeset
24
kono
parents:
diff changeset
25 HOOK_VECTOR (TARGETM_COMMON_INITIALIZER, gcc_targetm_common)
kono
parents:
diff changeset
26
kono
parents:
diff changeset
27 #undef HOOK_PREFIX
kono
parents:
diff changeset
28 #define HOOK_PREFIX "TARGET_"
kono
parents:
diff changeset
29
kono
parents:
diff changeset
30 /* Handle target switch DECODED for options structures OPTS and
kono
parents:
diff changeset
31 OPTS_SET, at location LOC. Return true if the switch was valid. */
kono
parents:
diff changeset
32 DEFHOOK
kono
parents:
diff changeset
33 (handle_option,
kono
parents:
diff changeset
34 "",
kono
parents:
diff changeset
35 bool, (struct gcc_options *opts, struct gcc_options *opts_set,
kono
parents:
diff changeset
36 const struct cl_decoded_option *decoded,
kono
parents:
diff changeset
37 location_t loc),
kono
parents:
diff changeset
38 default_target_handle_option)
kono
parents:
diff changeset
39
kono
parents:
diff changeset
40 DEFHOOK
kono
parents:
diff changeset
41 (option_init_struct,
kono
parents:
diff changeset
42 "Set target-dependent initial values of fields in @var{opts}.",
kono
parents:
diff changeset
43 void, (struct gcc_options *opts),
kono
parents:
diff changeset
44 hook_void_gcc_optionsp)
kono
parents:
diff changeset
45
kono
parents:
diff changeset
46 /* Set default optimizations for the target. */
kono
parents:
diff changeset
47 DEFHOOKPOD
kono
parents:
diff changeset
48 (option_optimization_table,
kono
parents:
diff changeset
49 "",
kono
parents:
diff changeset
50 const struct default_options *, empty_optimization_table)
kono
parents:
diff changeset
51
kono
parents:
diff changeset
52 DEFHOOK
kono
parents:
diff changeset
53 (option_default_params,
kono
parents:
diff changeset
54 "Set target-dependent default values for @option{--param} settings, using\
kono
parents:
diff changeset
55 calls to @code{set_default_param_value}.",
kono
parents:
diff changeset
56 void, (void),
kono
parents:
diff changeset
57 hook_void_void)
kono
parents:
diff changeset
58
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
59 DEFHOOK
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
60 (option_validate_param,
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
61 "Validate target-dependent value for @option{--param} settings, using\
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
62 calls to @code{set_param_value}.",
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
63 bool, (int, int),
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
64 default_option_validate_param)
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
65
111
kono
parents:
diff changeset
66 /* The initial value of target_flags. */
kono
parents:
diff changeset
67 DEFHOOKPOD
kono
parents:
diff changeset
68 (default_target_flags,
kono
parents:
diff changeset
69 "",
kono
parents:
diff changeset
70 int, 0)
kono
parents:
diff changeset
71
kono
parents:
diff changeset
72 /* Determine the type of unwind info to emit for exceptions. */
kono
parents:
diff changeset
73 DEFHOOK
kono
parents:
diff changeset
74 (except_unwind_info,
kono
parents:
diff changeset
75 "",
kono
parents:
diff changeset
76 enum unwind_info_type, (struct gcc_options *opts),
kono
parents:
diff changeset
77 default_except_unwind_info)
kono
parents:
diff changeset
78
kono
parents:
diff changeset
79 DEFHOOK
kono
parents:
diff changeset
80 (supports_split_stack,
kono
parents:
diff changeset
81 "Whether this target supports splitting the stack when the options\
kono
parents:
diff changeset
82 described in @var{opts} have been passed. This is called\
kono
parents:
diff changeset
83 after options have been parsed, so the target may reject splitting\
kono
parents:
diff changeset
84 the stack in some configurations. The default version of this hook\
kono
parents:
diff changeset
85 returns false. If @var{report} is true, this function may issue a warning\
kono
parents:
diff changeset
86 or error; if @var{report} is false, it must simply return a value",
kono
parents:
diff changeset
87 bool, (bool report, struct gcc_options *opts),
kono
parents:
diff changeset
88 hook_bool_bool_gcc_optionsp_false)
kono
parents:
diff changeset
89
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
90 DEFHOOK
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
91 (get_valid_option_values,
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
92 "The hook is used for options that have a non-trivial list of\
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
93 possible option values. OPTION_CODE is option code of opt_code\
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
94 enum type. PREFIX is used for bash completion and allows an implementation\
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
95 to return more specific completion based on the prefix. All string values\
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
96 should be allocated from heap memory and consumers should release them. \
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
97 The result will be pruned to cases with PREFIX if not NULL.",
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
98 vec<const char *>, (int option_code, const char *prefix),
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
99 default_get_valid_option_values)
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
100
111
kono
parents:
diff changeset
101 /* Leave the boolean fields at the end. */
kono
parents:
diff changeset
102
kono
parents:
diff changeset
103 /* True if unwinding tables should be generated by default. */
kono
parents:
diff changeset
104 DEFHOOKPOD
kono
parents:
diff changeset
105 (unwind_tables_default,
kono
parents:
diff changeset
106 "",
kono
parents:
diff changeset
107 bool, false)
kono
parents:
diff changeset
108
kono
parents:
diff changeset
109 /* True if arbitrary sections are supported. */
kono
parents:
diff changeset
110 DEFHOOKPOD
kono
parents:
diff changeset
111 (have_named_sections,
kono
parents:
diff changeset
112 "",
kono
parents:
diff changeset
113 bool, true)
kono
parents:
diff changeset
114
kono
parents:
diff changeset
115 DEFHOOKPOD
kono
parents:
diff changeset
116 (always_strip_dotdot,
kono
parents:
diff changeset
117 "True if @file{..} components should always be removed from directory names\
kono
parents:
diff changeset
118 computed relative to GCC's internal directories, false (default) if such\
kono
parents:
diff changeset
119 components should be preserved and directory names containing them passed\
kono
parents:
diff changeset
120 to other tools such as the linker.",
kono
parents:
diff changeset
121 bool, false)
kono
parents:
diff changeset
122
kono
parents:
diff changeset
123 HOOK_VECTOR_END (C90_EMPTY_HACK)
kono
parents:
diff changeset
124
kono
parents:
diff changeset
125 #undef HOOK_PREFIX