nameless arguments to be passed on the stack instead. This is done
by making @code{FUNCTION_ARG} return 0 whenever @var{named} is 0.
-@cindex @code{MUST_PASS_IN_STACK}, and @code{FUNCTION_ARG}
+@cindex @code{TARGET_MUST_PASS_IN_STACK}, and @code{FUNCTION_ARG}
@cindex @code{REG_PARM_STACK_SPACE}, and @code{FUNCTION_ARG}
-You may use the macro @code{MUST_PASS_IN_STACK (@var{mode}, @var{type})}
+You may use the hook @code{targetm.calls.must_pass_in_stack}
in the definition of this macro to determine if this argument is of a
type that must be passed in the stack. If @code{REG_PARM_STACK_SPACE}
is not defined and @code{FUNCTION_ARG} returns nonzero for such an
a register.
@end defmac
-@defmac MUST_PASS_IN_STACK (@var{mode}, @var{type})
-Define as a C expression that evaluates to nonzero if we do not know how
-to pass TYPE solely in registers. The file @file{expr.h} defines a
+@deftypefn {Target Hook} bool TARGET_MUST_PASS_IN_STACK (enum machine_mode @var{mode}, tree @var{type})
+This target hook should return @code{true} if we should not pass @var{type}
+solely in registers. The file @file{expr.h} defines a
definition that is usually appropriate, refer to @file{expr.h} for additional
documentation.
-@end defmac
+@end deftypefn
@defmac FUNCTION_INCOMING_ARG (@var{cum}, @var{mode}, @var{type}, @var{named})
Define this macro if the target machine has ``register windows'', so
@code{FUNCTION_INCOMING_ARG}, for the called function.
@end defmac
-@defmac FUNCTION_ARG_PASS_BY_REFERENCE (@var{cum}, @var{mode}, @var{type}, @var{named})
-A C expression that indicates when an argument must be passed by reference.
-If nonzero for an argument, a copy of that argument is made in memory and a
+@deftypefn {Target Hook} bool TARGET_PASS_BY_REFERENCE (CUMULATIVE_ARGS *@var{cum}, enum machine_mode @var{mode}, tree @var{type}, bool @var{named})
+This target hook should return @code{true} if an argument at the
+position indicated by @var{cum} should be passed by reference. This
+predicate is queried after target independent reasons for being
+passed by reference, such as @code{TREE_ADDRESSABLE (type)}.
+
+If the hook returns true, a copy of that argument is made in memory and a
pointer to the argument is passed instead of the argument itself.
The pointer is passed in whatever way is appropriate for passing a pointer
to that type.
-
-On machines where @code{REG_PARM_STACK_SPACE} is not defined, a suitable
-definition of this macro might be
-@smallexample
-#define FUNCTION_ARG_PASS_BY_REFERENCE\
-(CUM, MODE, TYPE, NAMED) \
- MUST_PASS_IN_STACK (MODE, TYPE)
-@end smallexample
-@c this is *still* too long. --mew 5feb93
-@end defmac
+@end deftypefn
@defmac FUNCTION_ARG_CALLEE_COPIES (@var{cum}, @var{mode}, @var{type}, @var{named})
If defined, a C expression that indicates when it is the called function's
@code{VA_ARG_EXPR}. The first two parameters correspond to the
arguments to @code{va_arg}; the latter two are as in
@code{gimplify.c:gimplify_expr}.
-
-You only need to define this hook if you previously defined
-@code{EXPAND_BUILTIN_VA_ARG}; it is pretty easy to reuse the same code
-for both. One significant difference is that
-@code{EXPAND_BUILTIN_VA_ARG} returns an address, whereas this hook
-produces an expression of type @var{type}, usually an @code{INDIRECT_REF}.
-
-Once you define this macro, you can change
-@code{EXPAND_BUILTIN_VA_ARG} to just abort, as it should never be
-called.
@end deftypefn
@node Scalar Return
@var{end} are both pointer expressions.
@end defmac
+The operating system may also require the stack to be made executable
+before calling the trampoline. To implement this requirement, define
+the following macro.
+
+@defmac ENABLE_EXECUTE_STACK
+Define this macro if certain operations must be performed before executing
+code located on the stack. The macro should expand to a series of C
+file-scope constructs (e.g. functions) and provide a unique entry point
+named @code{__enable_execute_stack}. The target is responsible for
+emitting calls to the entry point in the code, for example from the
+@code{INITIALIZE_TRAMPOLINE} macro.
+@end defmac
+
To use a standard subroutine, define the following macro. In addition,
you must make sure that the instructions in a trampoline fill an entire
cache line with identical instructions, or else ensure that the
mechanism will be used. Used by @code{__builtin_memset} when storing
values other than constant zero and by @code{__builtin_strcpy} when
when called with a constant source string.
-Defaults to @code{MOVE_BY_PIECES_P}.
+Defaults to to 1 if @code{move_by_pieces_ninsns} returns less
+than @code{MOVE_RATIO}.
@end defmac
@defmac USE_LOAD_POST_INCREMENT (@var{mode})
it to vary depending on what the instructions are, you must use
@samp{TARGET_SCHED_VARIABLE_ISSUE}.
-For the automaton based pipeline interface, you could define this hook
-to return the value of the macro @code{MAX_DFA_ISSUE_RATE}.
+You could define this hook to return the value of the macro
+@code{MAX_DFA_ISSUE_RATE}.
@end deftypefn
@deftypefn {Target Hook} int TARGET_SCHED_VARIABLE_ISSUE (FILE *@var{file}, int @var{verbose}, rtx @var{insn}, int @var{more})
output-dependence is maximum of one and the difference of latency
times of the first and the second insns. If these values are not
acceptable, you could use the hook to modify them too. See also
-@pxref{Automaton pipeline description}.
+@pxref{Processor pipeline description}.
@end deftypefn
@deftypefn {Target Hook} int TARGET_SCHED_ADJUST_PRIORITY (rtx @var{insn}, int @var{priority})
@var{verbose} is the verbose level provided by @option{-fsched-verbose-@var{n}}.
@end deftypefn
-@deftypefn {Target Hook} int TARGET_SCHED_USE_DFA_PIPELINE_INTERFACE (void)
-This hook is called many times during insn scheduling. If the hook
-returns nonzero, the automaton based pipeline description is used for
-insn scheduling. Otherwise the traditional pipeline description is
-used. The default is usage of the traditional pipeline description.
-
-You should also remember that to simplify the insn scheduler sources
-an empty traditional pipeline description interface is generated even
-if there is no a traditional pipeline description in the @file{.md}
-file. The same is true for the automaton based pipeline description.
-That means that you should be accurate in defining the hook.
-@end deftypefn
-
@deftypefn {Target Hook} int TARGET_SCHED_DFA_PRE_CYCLE_INSN (void)
The hook returns an RTL insn. The automaton state used in the
pipeline hazard recognizer is changed as if the insn were scheduled
The default is that FDEs are not given nonlocal labels.
@end deftypefn
+@deftypefn {Taget Hook} void TARGET_UNWIND_EMIT (FILE * @var{stream}, rtx @var{insn})
+This target hook emits and assembly directives required to unwind the
+given instruction. This is only used when TARGET_UNWIND_INFO is set.
+@end deftypefn
+
@node Exception Region Output
@subsection Assembler Commands for Exception Regions
instead of inline unwinders and @code{__unwind_function} in the non-@code{setjmp} case.
@end defmac
+@defmac TARGET_UNWIND_INFO
+Define this macro if your target has ABI specified unwind tables. Usually
+these will be output by @code{TARGET_UNWIND_EMIT}.
+@end defmac
+
@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
call @code{merge_attributes} to handle machine-independent merging.
@findex TARGET_DLLIMPORT_DECL_ATTRIBUTES
-If the only target-specific handling you require is @samp{dllimport} for
-Microsoft Windows targets, you should define the macro
-@code{TARGET_DLLIMPORT_DECL_ATTRIBUTES}. This links in a function
-called @code{merge_dllimport_decl_attributes} which can then be defined
-as the expansion of @code{TARGET_MERGE_DECL_ATTRIBUTES}. This is done
-in @file{i386/cygwin.h} and @file{i386/i386.c}, for example.
+If the only target-specific handling you require is @samp{dllimport}
+for Microsoft Windows targets, you should define the macro
+@code{TARGET_DLLIMPORT_DECL_ATTRIBUTES} to @code{1}. The compiler
+will then define a function called
+@code{merge_dllimport_decl_attributes} which can then be defined as
+the expansion of @code{TARGET_MERGE_DECL_ATTRIBUTES}. You can also
+add @code{handle_dll_attribute} in the attribute table for your port
+to perform initial processing of the @samp{dllimport} and
+@samp{dllexport} attributes. This is done in @file{i386/cygwin.h} and
+@file{i386/i386.c}, for example.
@end deftypefn
+@defmac TARGET_DECLSPEC
+Define this macro to a non-zero value if you want to treat
+@code{__declspec(X)} as equivalent to @code{__attribute((X))}. By
+default, this behavior is enabled only for targets that define
+@code{TARGET_DLLIMPORT_DECL_ATTRIBUTES}. The current implementation
+of @code{__declspec} is via a built-in macro, but you should not rely
+on this implementation detail.
+@end defmac
+
@deftypefn {Target Hook} void TARGET_INSERT_ATTRIBUTES (tree @var{node}, tree *@var{attr_ptr})
Define this target hook if you want to be able to add attributes to a decl
when it is being created. This is normally useful for back ends which
backend's targeted operating system.
@end deftypefn
+@deftypefn {Target Hook} bool TARGET_CXX_CDTOR_RETURNS_THIS (void)
+This hook should return @code{true} if constructors and destructors return
+the address of the object created/destroyed. The default is to return
+@code{false}.
+@end deftypefn
+
@node Misc
@section Miscellaneous Parameters
@cindex parameters, miscellaneous
they have no equivalent in the source language (for example, SIMD vector
instructions or prefetch instructions).
-To create a built-in function, call the function @code{builtin_function}
+To create a built-in function, call the function
+@code{lang_hooks.builtin_function}
which is defined by the language front end. You can use any type nodes set
up by @code{build_common_tree_nodes} and @code{build_common_tree_nodes_2};
only language front ends that use those two functions will call
functions, if a target supports aliases (ie. defines
@code{ASM_OUTPUT_DEF}), @code{false} otherwise,
@end deftypefn
+
+@defmac TARGET_FORMAT_TYPES
+If defined, this macro is the name of a global variable containing
+target-specific format checking information for the @option{-Wformat}
+option. The default is to have no target-specific format checks.
+@end defmac
+
+@defmac TARGET_N_FORMAT_TYPES
+If defined, this macro is the number of entries in
+@code{TARGET_FORMAT_TYPES}.
+@end defmac