@c prevent bad page break with this line
You can control the compilation driver.
-@defmac SWITCH_TAKES_ARG (@var{char})
-A C expression which determines whether the option @option{-@var{char}}
-takes arguments. The value should be the number of arguments that
-option takes--zero, for many options.
-
-By default, this macro is defined as
-@code{DEFAULT_SWITCH_TAKES_ARG}, which handles the standard options
-properly. You need not define @code{SWITCH_TAKES_ARG} unless you
-wish to add additional options which take arguments. Any redefinition
-should call @code{DEFAULT_SWITCH_TAKES_ARG} and then check for
-additional options.
-@end defmac
-
-@defmac WORD_SWITCH_TAKES_ARG (@var{name})
-A C expression which determines whether the option @option{-@var{name}}
-takes arguments. The value should be the number of arguments that
-option takes--zero, for many options. This macro rather than
-@code{SWITCH_TAKES_ARG} is used for multi-character option names.
-
-By default, this macro is defined as
-@code{DEFAULT_WORD_SWITCH_TAKES_ARG}, which handles the standard options
-properly. You need not define @code{WORD_SWITCH_TAKES_ARG} unless you
-wish to add additional options which take arguments. Any redefinition
-should call @code{DEFAULT_WORD_SWITCH_TAKES_ARG} and then check for
-additional options.
-@end defmac
-
-@defmac SWITCH_CURTAILS_COMPILATION (@var{char})
-A C expression which determines whether the option @option{-@var{char}}
-stops compilation before the generation of an executable. The value is
-boolean, nonzero if the option does stop an executable from being
-generated, zero otherwise.
-
-By default, this macro is defined as
-@code{DEFAULT_SWITCH_CURTAILS_COMPILATION}, which handles the standard
-options properly. You need not define
-@code{SWITCH_CURTAILS_COMPILATION} unless you wish to add additional
-options which affect the generation of an executable. Any redefinition
-should call @code{DEFAULT_SWITCH_CURTAILS_COMPILATION} and then check
-for additional options.
-@end defmac
-
-@defmac TARGET_OPTION_TRANSLATE_TABLE
-If defined, a list of pairs of strings, the first of which is a
-potential command line target to the @file{gcc} driver program, and the
-second of which is a space-separated (tabs and other whitespace are not
-supported) list of options with which to replace the first option. The
-target defining this list is responsible for assuring that the results
-are valid. Replacement options may not be the @code{--opt} style, they
-must be the @code{-opt} style. It is the intention of this macro to
-provide a mechanism for substitution that affects the multilibs chosen,
-such as one option that enables many options, some of which select
-multilibs. Example nonsensical definition, where @option{-malt-abi},
-@option{-EB}, and @option{-mspoo} cause different multilibs to be chosen:
-
-@smallexample
-#define TARGET_OPTION_TRANSLATE_TABLE \
-@{ "-fast", "-march=fast-foo -malt-abi -I/usr/fast-foo" @}, \
-@{ "-compat", "-EB -malign=4 -mspoo" @}
-@end smallexample
-@end defmac
-
@defmac DRIVER_SELF_SPECS
A list of specs for the driver itself. It should be a suitable
initializer for an array of strings, with no surrounding braces.
should use @code{TARGET_HANDLE_C_OPTION} instead.
@end deftypefn
+@hook TARGET_OBJC_CONSTRUCT_STRING_OBJECT
+
+@hook TARGET_STRING_OBJECT_REF_TYPE_P
+
+@hook TARGET_CHECK_STRING_OBJECT_FORMAT_ARG
+
@defmac TARGET_VERSION
This macro is a C statement to print on @code{stderr} a string
describing the particular machine description choice. Every machine
frontends.
@end defmac
-@hook TARGET_OPTION_OPTIMIZATION
+@hook TARGET_OPTION_OPTIMIZATION_TABLE
Some machines may desire to change what optimizations are performed for
-various optimization levels. This hook, if defined, is executed once
+various optimization levels. This variable, if defined, describes
+options to enable at particular sets of optimization levels. These
+options are processed once
just after the optimization level is determined and before the remainder
-of the command options have been parsed. Values set in this macro are
-used as the default values for the other command line options.
-
-@var{level} is the optimization level specified; 2 if @option{-O2} is
-specified, 1 if @option{-O} is specified, and 0 if neither is specified.
+of the command options have been parsed, so may be overridden by other
+options passed explicily.
-@var{size} is nonzero if @option{-Os} is specified and zero otherwise.
-
-This macro is run once at program startup and when the optimization
+This processing is run once at program startup and when the optimization
options are changed via @code{#pragma GCC optimize} or by using the
@code{optimize} attribute.
-
-@strong{Do not examine @code{write_symbols} in
-this hook!} The debugging options are not supposed to alter the
-generated code.
-@end deftypefn
+@end deftypevr
@hook TARGET_OPTION_INIT_STRUCT
line options found in its @file{.opt} file.
@end deftypefn
-@defmac CAN_DEBUG_WITHOUT_FP
-Define this macro if debugging can be performed even without a frame
-pointer. If this macro is defined, GCC will turn on the
-@option{-fomit-frame-pointer} option whenever @option{-O} is specified.
-@end defmac
-
@defmac SWITCHABLE_TARGET
Some targets need to switch between substantially different subtargets
during compilation. For example, the MIPS target has one subtarget for
macro need not be a constant.
@end defmac
-@defmac LIBGCC2_WORDS_BIG_ENDIAN
-Define this macro if @code{WORDS_BIG_ENDIAN} is not constant. This must be a
-constant value with the same meaning as @code{WORDS_BIG_ENDIAN}, which will be
-used only when compiling @file{libgcc2.c}. Typically the value will be set
-based on preprocessor defines.
-@end defmac
-
@defmac FLOAT_WORDS_BIG_ENDIAN
Define this macro to have the value 1 if @code{DFmode}, @code{XFmode} or
@code{TFmode} floating point numbers are stored in memory with the word
One use of this macro is to increase alignment of medium-size data to
make it all fit in fewer cache lines.
+
+If the value of this macro has a type, it should be an unsigned type.
@end defmac
@defmac STACK_SLOT_ALIGNMENT (@var{type}, @var{mode}, @var{basic-align})
This macro is to set alignment of stack slot to the maximum alignment
of all possible modes which the slot may have.
+
+If the value of this macro has a type, it should be an unsigned type.
@end defmac
@defmac LOCAL_DECL_ALIGNMENT (@var{decl})
One use of this macro is to increase alignment of medium-size data to
make it all fit in fewer cache lines.
+
+If the value of this macro has a type, it should be an unsigned type.
@end defmac
@defmac MINIMUM_ALIGNMENT (@var{exp}, @var{mode}, @var{align})
@findex global_regs
@findex reg_names
@findex reg_class_contents
-@defmac CONDITIONAL_REGISTER_USAGE
-Zero or more C statements that may conditionally modify five variables
+@hook TARGET_CONDITIONAL_REGISTER_USAGE
+This hook may conditionally modify five variables
@code{fixed_regs}, @code{call_used_regs}, @code{global_regs},
@code{reg_names}, and @code{reg_class_contents}, to take into account
any dependence of these register sets on target flags. The first three
@option{-fcall-used-@var{reg}} and @option{-fcall-saved-@var{reg}}
command options have been applied.
-You need not define this macro if it has no work to do.
-
@cindex disabling certain registers
@cindex controlling register usage
If the usage of an entire class of registers depends on the target
of the insn patterns whose constraints permit this class are
controlled by target switches, then GCC will automatically avoid using
these registers when the target switches are opposed to them.)
-@end defmac
+@end deftypefn
@defmac INCOMING_REGNO (@var{out})
Define this macro if the target machine has register windows. This C
@defmac REGNO_OK_FOR_BASE_P (@var{num})
A C expression which is nonzero if register number @var{num} is
suitable for use as a base register in operand addresses.
-Like @code{TARGET_LEGITIMATE_ADDRESS_P}, this macro should also
-define a strict and a non-strict variant. Both variants behave
-the same for hard register; for pseudos, the strict variant will
-pass only those that have been allocated to a valid hard registers,
-while the non-strict variant will pass all pseudos.
-
-@findex REG_OK_STRICT
-Compiler source files that want to use the strict variant of this and
-other macros define the macro @code{REG_OK_STRICT}. You should use an
-@code{#ifdef REG_OK_STRICT} conditional to define the strict variant in
-that case and the non-strict variant otherwise.
@end defmac
@defmac REGNO_MODE_OK_FOR_BASE_P (@var{num}, @var{mode})
@code{REGNO_OK_FOR_BASE_P}. The mode may be @code{VOIDmode} for
addresses that appear outside a @code{MEM}, i.e., as an
@code{address_operand}.
-
-This macro also has strict and non-strict variants.
@end defmac
@defmac REGNO_MODE_OK_FOR_REG_BASE_P (@var{num}, @var{mode})
Use of this macro is deprecated; please use the more general
@code{REGNO_MODE_CODE_OK_FOR_BASE_P}.
-
-This macro also has strict and non-strict variants.
@end defmac
@defmac REGNO_MODE_CODE_OK_FOR_BASE_P (@var{num}, @var{mode}, @var{outer_code}, @var{index_code})
corresponding index expression if @var{outer_code} is @code{PLUS};
@code{SCRATCH} otherwise. The mode may be @code{VOIDmode} for addresses
that appear outside a @code{MEM}, i.e., as an @code{address_operand}.
-
-This macro also has strict and non-strict variants.
@end defmac
@defmac REGNO_OK_FOR_INDEX_P (@var{num})
may serve in each capacity. The compiler will try both labelings,
looking for one that is valid, and will reload one or both registers
only if neither labeling works.
-
-This macro also has strict and non-strict variants.
@end defmac
+@hook TARGET_PREFERRED_RENAME_CLASS
+
@hook TARGET_PREFERRED_RELOAD_CLASS
A target hook that places additional restrictions on the register class
to use when it is necessary to copy value @var{x} into a register in class
macro or @code{IRA_COVER_CLASSES} in order to use the integrated register
allocator with Chaitin-Briggs coloring. If the macro is not defined,
the only available coloring algorithm is Chow's priority coloring.
+
+This hook must not be modified from @code{NULL} to non-@code{NULL} or
+vice versa by command-line option processing.
@end deftypefn
@defmac IRA_COVER_CLASSES
@smallexample
#define PUSH_ROUNDING(BYTES) (((BYTES) + 1) & ~1)
@end smallexample
+
+If the value of this macro has a type, it should be an unsigned type.
@end defmac
@findex current_function_outgoing_args_size
@code{downward} to pad below, or @code{none} to inhibit padding.
The @emph{amount} of padding is always just enough to reach the next
-multiple of @code{FUNCTION_ARG_BOUNDARY}; this macro does not control
-it.
+multiple of @code{TARGET_FUNCTION_ARG_BOUNDARY}; this macro does not
+control it.
This macro has a default definition which is right for most systems.
For little-endian machines, the default is to pad upward. For
required.
@end defmac
-@defmac FUNCTION_ARG_BOUNDARY (@var{mode}, @var{type})
-If defined, a C expression that gives the alignment boundary, in bits,
-of an argument with the specified mode and type. If it is not defined,
-@code{PARM_BOUNDARY} is used for all arguments.
-@end defmac
+@hook TARGET_FUNCTION_ARG_BOUNDARY
+This hook returns the the alignment boundary, in bits, of an argument
+with the specified mode and type. The default hook returns
+@code{PARM_BOUNDARY} for all arguments.
+@end deftypefn
@defmac FUNCTION_ARG_REGNO_P (@var{regno})
A C expression that is nonzero if @var{regno} is the number of a hard
nothing when you use @option{-freg-struct-return} mode.
@end defmac
+@hook TARGET_GET_RAW_RESULT_MODE
+
+@hook TARGET_GET_RAW_ARG_MODE
+
@node Caller Saves
@subsection Caller-Saves Register Allocation
@noindent
and should @code{goto @var{label}} if the address @var{x} is a valid
address on the target machine for a memory operand of mode @var{mode}.
-Whether the strict or non-strict variants are desired is defined by
-the @code{REG_OK_STRICT} macro introduced earlier in this section.
+
+@findex REG_OK_STRICT
+Compiler source files that want to use the strict variant of this
+macro define the macro @code{REG_OK_STRICT}. You should use an
+@code{#ifdef REG_OK_STRICT} conditional to define the strict variant in
+that case and the non-strict variant otherwise.
+
Using the hook is usually simpler because it limits the number of
files that are recompiled when changes are made.
@end deftypefn
@menu
* CC0 Condition Codes:: Old style representation of condition codes.
* MODE_CC Condition Codes:: Modern representation of condition codes.
-* Cond. Exec. Macros:: Macros to control conditional execution.
+* Cond Exec Macros:: Macros to control conditional execution.
@end menu
@node CC0 Condition Codes
returns @code{VOIDmode}.
@end deftypefn
-@node Cond. Exec. Macros
+@node Cond Exec Macros
@subsection Macros to control conditional execution
@findex conditional execution
@findex predication
The default is that any ready insns can be chosen to be issued.
@end deftypefn
+@hook TARGET_SCHED_FIRST_CYCLE_MULTIPASS_BEGIN
+This hook prepares the target backend for a new round of multipass
+scheduling.
+@end deftypefn
+
+@hook TARGET_SCHED_FIRST_CYCLE_MULTIPASS_ISSUE
+This hook is called when multipass scheduling evaluates instruction INSN.
+@end deftypefn
+
+@hook TARGET_SCHED_FIRST_CYCLE_MULTIPASS_BACKTRACK
+This is called when multipass scheduling backtracks from evaluation of
+an instruction.
+@end deftypefn
+
+@hook TARGET_SCHED_FIRST_CYCLE_MULTIPASS_END
+This hook notifies the target about the result of the concluded current
+round of multipass scheduling.
+@end deftypefn
+
+@hook TARGET_SCHED_FIRST_CYCLE_MULTIPASS_INIT
+This hook initilizes target-specific data used in multipass scheduling.
+@end deftypefn
+
+@hook TARGET_SCHED_FIRST_CYCLE_MULTIPASS_FINI
+This hook finilizes target-specific data used in multipass scheduling.
+@end deftypefn
+
@hook TARGET_SCHED_DFA_NEW_CYCLE
This hook is called by the insn scheduler before issuing @var{insn}
on cycle @var{clock}. If the hook returns nonzero,
this section is associated.
@end deftypefn
+@hook TARGET_ASM_FUNCTION_SECTION
+Return preferred text (sub)section for function @var{decl}.
+Main purpose of this function is to separate cold, normal and hot
+functions. @var{startup} is true when function is known to be used only
+at startup (from static constructors or it is @code{main()}).
+@var{exit} is true when function is known to be used only at exit
+(from static destructors).
+Return NULL if function should go to default text section.
+@end deftypefn
+
@hook TARGET_HAVE_NAMED_SECTIONS
This flag is true if the target supports @code{TARGET_ASM_NAMED_SECTION}.
+It must not be modified by command-line option processing.
@end deftypevr
@anchor{TARGET_HAVE_SWITCHABLE_BSS_SECTIONS}
systems. This macro is used in @code{assemble_name}.
@end defmac
+@hook TARGET_MANGLE_ASSEMBLER_NAME
+
@defmac ASM_OUTPUT_SYMBOL_REF (@var{stream}, @var{sym})
A C statement (sans semicolon) to output a reference to
@code{SYMBOL_REF} @var{sym}. If not defined, @code{assemble_name}
Define this macro as a C string constant containing the file name to use
to execute @command{nm}. The default is to search the path normally for
@command{nm}.
+@end defmac
+
+@defmac NM_FLAGS
+@command{collect2} calls @command{nm} to scan object files for static
+constructors and destructors and LTO info. By default, @option{-n} is
+passed. Define @code{NM_FLAGS} to a C string constant if other options
+are needed to get the same output formut as GNU @command{nm -n}
+produces.
+@end defmac
If your system supports shared libraries and has a program to list the
dynamic dependencies of a given library or executable, you can define
these macros to enable support for running initialization and
termination functions in shared libraries:
-@end defmac
@defmac LDD_SUFFIX
Define this macro to a C string constant containing the name of the program
-which lists dynamic dependencies, like @command{"ldd"} under SunOS 4.
+which lists dynamic dependencies, like @command{ldd} under SunOS 4.
@end defmac
@defmac PARSE_LDD_OUTPUT (@var{ptr})
to registers using alternate names.
@end defmac
+@defmac OVERLAPPING_REGISTER_NAMES
+If defined, a C initializer for an array of structures containing a
+name, a register number and a count of the number of consecutive
+machine registers the name overlaps. This macro defines additional
+names for hard registers, thus allowing the @code{asm} option in
+declarations to refer to registers using alternate names. Unlike
+@code{ADDITIONAL_REGISTER_NAMES}, this macro should be used when the
+register name implies multiple underlying registers.
+
+This macro should be used when it is important that a clobber in an
+@code{asm} statement clobbers all the underlying values implied by the
+register name. For example, on ARM, clobbering the double-precision
+VFP register ``d0'' implies clobbering both single-precision registers
+``s0'' and ``s1''.
+@end defmac
+
@defmac ASM_OUTPUT_OPCODE (@var{stream}, @var{ptr})
Define this macro if you are using an unusual assembler that
requires different names for the machine instructions.
default implementation of this hook never returns @code{UI_NONE}.
Note that the value returned by this hook should be constant. It should
-not depend on anything except command-line switches. In particular, the
+not depend on anything except the command-line switches described by
+@var{opts}. In particular, the
setting @code{UI_SJLJ} must be fixed at compiler start-up as C pre-processor
macros and builtin functions related to exception handling are set up
depending on this setting.
The default implementation of the hook first honors the
@option{--enable-sjlj-exceptions} configure option, then
-@code{DWARF2_UNWIND_INFO}, and finally defaults to @code{UI_SJLJ}.
+@code{DWARF2_UNWIND_INFO}, and finally defaults to @code{UI_SJLJ}. If
+@code{DWARF2_UNWIND_INFO} depends on command-line options, the target
+must define this hook so that @var{opts} is used correctly.
@end deftypefn
@hook TARGET_UNWIND_TABLES_DEFAULT
This variable should be set to @code{true} if the target ABI requires unwinding
-tables even when exceptions are not used.
+tables even when exceptions are not used. It must not be modified by
+command-line option processing.
@end deftypevr
-@defmac MUST_USE_SJLJ_EXCEPTIONS
-This macro need only be defined if @code{DWARF2_UNWIND_INFO} is
-runtime-variable. In that case, @file{except.h} cannot correctly
-determine the corresponding definition of @code{MUST_USE_SJLJ_EXCEPTIONS},
-so the target must provide it directly.
-@end defmac
-
@defmac DONT_USE_BUILTIN_SETJMP
Define this macro to 1 if the @code{setjmp}/@code{longjmp}-based scheme
should use the @code{setjmp}/@code{longjmp} functions from the C library
how to build this object file.
@end deftypefun
-@findex #pragma
-@findex pragma
-@defmac HANDLE_SYSV_PRAGMA
-Define this macro (to a value of 1) if you want the System V style
-pragmas @samp{#pragma pack(<n>)} and @samp{#pragma weak <name>
-[=<value>]} to be supported by gcc.
-
-The pack pragma specifies the maximum alignment (in bytes) of fields
-within a structure, in much the same way as the @samp{__aligned__} and
-@samp{__packed__} @code{__attribute__}s do. A pack value of zero resets
-the behavior to the default.
-
-A subtlety for Microsoft Visual C/C++ style bit-field packing
-(e.g.@: -mms-bitfields) for targets that support it:
-When a bit-field is inserted into a packed record, the whole size
-of the underlying type is used by one or more same-size adjacent
-bit-fields (that is, if its long:3, 32 bits is used in the record,
-and any additional adjacent long bit-fields are packed into the same
-chunk of 32 bits. However, if the size changes, a new field of that
-size is allocated).
-
-If both MS bit-fields and @samp{__attribute__((packed))} are used,
-the latter will take precedence. If @samp{__attribute__((packed))} is
-used on a single field when MS bit-fields are in use, it will take
-precedence for that field, but the alignment of the rest of the structure
-may affect its placement.
-
-The weak pragma only works if @code{SUPPORTS_WEAK} and
-@code{ASM_WEAKEN_LABEL} are defined. If enabled it allows the creation
-of specifically named weak labels, optionally with a value.
-@end defmac
-
-@findex #pragma
-@findex pragma
-@defmac HANDLE_PRAGMA_PACK_PUSH_POP
-Define this macro (to a value of 1) if you want to support the Win32
-style pragmas @samp{#pragma pack(push[,@var{n}])} and @samp{#pragma
-pack(pop)}. The @samp{pack(push,[@var{n}])} pragma specifies the maximum
-alignment (in bytes) of fields within a structure, in much the same way as
-the @samp{__aligned__} and @samp{__packed__} @code{__attribute__}s do. A
-pack value of zero resets the behavior to the default. Successive
-invocations of this pragma cause the previous values to be stacked, so
-that invocations of @samp{#pragma pack(pop)} will return to the previous
-value.
-@end defmac
-
@defmac HANDLE_PRAGMA_PACK_WITH_EXPANSION
-Define this macro, as well as
-@code{HANDLE_SYSV_PRAGMA}, if macros should be expanded in the
+Define this macro if macros should be expanded in the
arguments of @samp{#pragma pack}.
@end defmac