xref: /dflybsd-src/contrib/gcc-8.0/gcc/common/common-target.def (revision 38fd149817dfbff97799f62fcb70be98c4e32523)
1*38fd1498Szrj/* Target hook definitions for common hooks.
2*38fd1498Szrj   Copyright (C) 2011-2018 Free Software Foundation, Inc.
3*38fd1498Szrj
4*38fd1498Szrj   This program is free software; you can redistribute it and/or modify it
5*38fd1498Szrj   under the terms of the GNU General Public License as published by the
6*38fd1498Szrj   Free Software Foundation; either version 3, or (at your option) any
7*38fd1498Szrj   later version.
8*38fd1498Szrj
9*38fd1498Szrj   This program is distributed in the hope that it will be useful,
10*38fd1498Szrj   but WITHOUT ANY WARRANTY; without even the implied warranty of
11*38fd1498Szrj   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12*38fd1498Szrj   GNU General Public License for more details.
13*38fd1498Szrj
14*38fd1498Szrj   You should have received a copy of the GNU General Public License
15*38fd1498Szrj   along with this program; see the file COPYING3.  If not see
16*38fd1498Szrj   <http://www.gnu.org/licenses/>.  */
17*38fd1498Szrj
18*38fd1498Szrj/* See target-hooks-macros.h for details of macros that should be
19*38fd1498Szrj   provided by the including file, and how to use them here.  */
20*38fd1498Szrj#include "target-hooks-macros.h"
21*38fd1498Szrj
22*38fd1498Szrj#undef HOOK_TYPE
23*38fd1498Szrj#define HOOK_TYPE "Common Target Hook"
24*38fd1498Szrj
25*38fd1498SzrjHOOK_VECTOR (TARGETM_COMMON_INITIALIZER, gcc_targetm_common)
26*38fd1498Szrj
27*38fd1498Szrj#undef HOOK_PREFIX
28*38fd1498Szrj#define HOOK_PREFIX "TARGET_"
29*38fd1498Szrj
30*38fd1498Szrj/* Handle target switch DECODED for options structures OPTS and
31*38fd1498Szrj   OPTS_SET, at location LOC.  Return true if the switch was valid.  */
32*38fd1498SzrjDEFHOOK
33*38fd1498Szrj(handle_option,
34*38fd1498Szrj "",
35*38fd1498Szrj bool, (struct gcc_options *opts, struct gcc_options *opts_set,
36*38fd1498Szrj	const struct cl_decoded_option *decoded,
37*38fd1498Szrj	location_t loc),
38*38fd1498Szrj default_target_handle_option)
39*38fd1498Szrj
40*38fd1498SzrjDEFHOOK
41*38fd1498Szrj(option_init_struct,
42*38fd1498Szrj"Set target-dependent initial values of fields in @var{opts}.",
43*38fd1498Szrj void, (struct gcc_options *opts),
44*38fd1498Szrj hook_void_gcc_optionsp)
45*38fd1498Szrj
46*38fd1498Szrj/* Set default optimizations for the target.  */
47*38fd1498SzrjDEFHOOKPOD
48*38fd1498Szrj(option_optimization_table,
49*38fd1498Szrj "",
50*38fd1498Szrj const struct default_options *, empty_optimization_table)
51*38fd1498Szrj
52*38fd1498SzrjDEFHOOK
53*38fd1498Szrj(option_default_params,
54*38fd1498Szrj"Set target-dependent default values for @option{--param} settings, using\
55*38fd1498Szrj calls to @code{set_default_param_value}.",
56*38fd1498Szrj void, (void),
57*38fd1498Szrj hook_void_void)
58*38fd1498Szrj
59*38fd1498Szrj/* The initial value of target_flags.  */
60*38fd1498SzrjDEFHOOKPOD
61*38fd1498Szrj(default_target_flags,
62*38fd1498Szrj "",
63*38fd1498Szrj int, 0)
64*38fd1498Szrj
65*38fd1498Szrj/* Determine the type of unwind info to emit for exceptions.  */
66*38fd1498SzrjDEFHOOK
67*38fd1498Szrj(except_unwind_info,
68*38fd1498Szrj "",
69*38fd1498Szrj enum unwind_info_type, (struct gcc_options *opts),
70*38fd1498Szrj default_except_unwind_info)
71*38fd1498Szrj
72*38fd1498SzrjDEFHOOK
73*38fd1498Szrj(supports_split_stack,
74*38fd1498Szrj "Whether this target supports splitting the stack when the options\
75*38fd1498Szrj described in @var{opts} have been passed.  This is called\
76*38fd1498Szrj after options have been parsed, so the target may reject splitting\
77*38fd1498Szrj the stack in some configurations.  The default version of this hook\
78*38fd1498Szrj returns false.  If @var{report} is true, this function may issue a warning\
79*38fd1498Szrj or error; if @var{report} is false, it must simply return a value",
80*38fd1498Szrj bool, (bool report, struct gcc_options *opts),
81*38fd1498Szrj hook_bool_bool_gcc_optionsp_false)
82*38fd1498Szrj
83*38fd1498Szrj/* Leave the boolean fields at the end.  */
84*38fd1498Szrj
85*38fd1498Szrj/* True if unwinding tables should be generated by default.  */
86*38fd1498SzrjDEFHOOKPOD
87*38fd1498Szrj(unwind_tables_default,
88*38fd1498Szrj "",
89*38fd1498Szrj bool, false)
90*38fd1498Szrj
91*38fd1498Szrj/* True if arbitrary sections are supported.  */
92*38fd1498SzrjDEFHOOKPOD
93*38fd1498Szrj(have_named_sections,
94*38fd1498Szrj "",
95*38fd1498Szrj bool, true)
96*38fd1498Szrj
97*38fd1498SzrjDEFHOOKPOD
98*38fd1498Szrj(always_strip_dotdot,
99*38fd1498Szrj "True if @file{..} components should always be removed from directory names\
100*38fd1498Szrj computed relative to GCC's internal directories, false (default) if such\
101*38fd1498Szrj components should be preserved and directory names containing them passed\
102*38fd1498Szrj to other tools such as the linker.",
103*38fd1498Szrj bool, false)
104*38fd1498Szrj
105*38fd1498SzrjHOOK_VECTOR_END (C90_EMPTY_HACK)
106*38fd1498Szrj
107*38fd1498Szrj#undef HOOK_PREFIX
108