|
|
|
@ -5228,9 +5228,8 @@ x86_elf_aligned_common (FILE *file,
|
|
|
|
|
ASM_OUTPUT_ALIGNED_BSS. */
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
x86_output_aligned_bss (FILE *file, tree decl ATTRIBUTE_UNUSED,
|
|
|
|
|
const char *name, unsigned HOST_WIDE_INT size,
|
|
|
|
|
int align)
|
|
|
|
|
x86_output_aligned_bss (FILE *file, tree decl, const char *name,
|
|
|
|
|
unsigned HOST_WIDE_INT size, int align)
|
|
|
|
|
{
|
|
|
|
|
if ((ix86_cmodel == CM_MEDIUM || ix86_cmodel == CM_MEDIUM_PIC)
|
|
|
|
|
&& size > (unsigned int)ix86_section_threshold)
|
|
|
|
@ -5360,7 +5359,7 @@ ix86_function_ok_for_sibcall (tree decl, tree exp)
|
|
|
|
|
static tree
|
|
|
|
|
ix86_handle_cconv_attribute (tree *node, tree name,
|
|
|
|
|
tree args,
|
|
|
|
|
int flags ATTRIBUTE_UNUSED,
|
|
|
|
|
int,
|
|
|
|
|
bool *no_add_attrs)
|
|
|
|
|
{
|
|
|
|
|
if (TREE_CODE (*node) != FUNCTION_TYPE
|
|
|
|
@ -5504,8 +5503,7 @@ ix86_handle_cconv_attribute (tree *node, tree name,
|
|
|
|
|
attributes that we expect elsewhere. */
|
|
|
|
|
|
|
|
|
|
static tree
|
|
|
|
|
ix86_handle_tm_regparm_attribute (tree *node, tree name ATTRIBUTE_UNUSED,
|
|
|
|
|
tree args ATTRIBUTE_UNUSED,
|
|
|
|
|
ix86_handle_tm_regparm_attribute (tree *node, tree, tree,
|
|
|
|
|
int flags, bool *no_add_attrs)
|
|
|
|
|
{
|
|
|
|
|
tree alt;
|
|
|
|
@ -7544,7 +7542,7 @@ ix86_function_arg (cumulative_args_t cum_v, enum machine_mode omode,
|
|
|
|
|
|
|
|
|
|
static bool
|
|
|
|
|
ix86_pass_by_reference (cumulative_args_t cum_v, enum machine_mode mode,
|
|
|
|
|
const_tree type, bool named ATTRIBUTE_UNUSED)
|
|
|
|
|
const_tree type, bool)
|
|
|
|
|
{
|
|
|
|
|
CUMULATIVE_ARGS *cum = get_cumulative_args (cum_v);
|
|
|
|
|
|
|
|
|
@ -7973,8 +7971,7 @@ ix86_function_value_1 (const_tree valtype, const_tree fntype_or_decl,
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static rtx
|
|
|
|
|
ix86_function_value (const_tree valtype, const_tree fntype_or_decl,
|
|
|
|
|
bool outgoing ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_function_value (const_tree valtype, const_tree fntype_or_decl, bool)
|
|
|
|
|
{
|
|
|
|
|
enum machine_mode mode, orig_mode;
|
|
|
|
|
|
|
|
|
@ -8021,7 +8018,7 @@ ix86_libcall_value (enum machine_mode mode)
|
|
|
|
|
/* Return true iff type is returned in memory. */
|
|
|
|
|
|
|
|
|
|
static bool
|
|
|
|
|
ix86_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_return_in_memory (const_tree type, const_tree fntype)
|
|
|
|
|
{
|
|
|
|
|
#ifdef SUBTARGET_RETURN_IN_MEMORY
|
|
|
|
|
return SUBTARGET_RETURN_IN_MEMORY (type, fntype);
|
|
|
|
@ -8315,8 +8312,7 @@ setup_incoming_varargs_ms_64 (CUMULATIVE_ARGS *cum)
|
|
|
|
|
|
|
|
|
|
static void
|
|
|
|
|
ix86_setup_incoming_varargs (cumulative_args_t cum_v, enum machine_mode mode,
|
|
|
|
|
tree type, int *pretend_size ATTRIBUTE_UNUSED,
|
|
|
|
|
int no_rtl)
|
|
|
|
|
tree type, int *, int no_rtl)
|
|
|
|
|
{
|
|
|
|
|
CUMULATIVE_ARGS *cum = get_cumulative_args (cum_v);
|
|
|
|
|
CUMULATIVE_ARGS next_cum;
|
|
|
|
@ -11767,8 +11763,7 @@ ix86_expand_epilogue (int style)
|
|
|
|
|
/* Reset from the function's potential modifications. */
|
|
|
|
|
|
|
|
|
|
static void
|
|
|
|
|
ix86_output_function_epilogue (FILE *file ATTRIBUTE_UNUSED,
|
|
|
|
|
HOST_WIDE_INT size ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_output_function_epilogue (FILE *file ATTRIBUTE_UNUSED, HOST_WIDE_INT)
|
|
|
|
|
{
|
|
|
|
|
if (pic_offset_table_rtx)
|
|
|
|
|
SET_REGNO (pic_offset_table_rtx, REAL_PIC_OFFSET_TABLE_REGNUM);
|
|
|
|
@ -12390,9 +12385,7 @@ ix86_decompose_address (rtx addr, struct ix86_address *out)
|
|
|
|
|
requires to two regs - that would mean more pseudos with longer
|
|
|
|
|
lifetimes. */
|
|
|
|
|
static int
|
|
|
|
|
ix86_address_cost (rtx x, enum machine_mode mode ATTRIBUTE_UNUSED,
|
|
|
|
|
addr_space_t as ATTRIBUTE_UNUSED,
|
|
|
|
|
bool speed ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_address_cost (rtx x, enum machine_mode, addr_space_t, bool)
|
|
|
|
|
{
|
|
|
|
|
struct ix86_address parts;
|
|
|
|
|
int cost = 1;
|
|
|
|
@ -12459,7 +12452,7 @@ darwin_local_data_pic (rtx disp)
|
|
|
|
|
satisfies CONSTANT_P. */
|
|
|
|
|
|
|
|
|
|
static bool
|
|
|
|
|
ix86_legitimate_constant_p (enum machine_mode mode ATTRIBUTE_UNUSED, rtx x)
|
|
|
|
|
ix86_legitimate_constant_p (enum machine_mode, rtx x)
|
|
|
|
|
{
|
|
|
|
|
switch (GET_CODE (x))
|
|
|
|
|
{
|
|
|
|
@ -12784,10 +12777,8 @@ legitimate_pic_address_disp_p (rtx disp)
|
|
|
|
|
0 if it should not. */
|
|
|
|
|
|
|
|
|
|
bool
|
|
|
|
|
ix86_legitimize_reload_address (rtx x,
|
|
|
|
|
enum machine_mode mode ATTRIBUTE_UNUSED,
|
|
|
|
|
int opnum, int type,
|
|
|
|
|
int ind_levels ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_legitimize_reload_address (rtx x, enum machine_mode, int opnum, int type,
|
|
|
|
|
int)
|
|
|
|
|
{
|
|
|
|
|
/* Reload can generate:
|
|
|
|
|
|
|
|
|
@ -12884,8 +12875,7 @@ ix86_validate_address_register (rtx op)
|
|
|
|
|
be recognized. */
|
|
|
|
|
|
|
|
|
|
static bool
|
|
|
|
|
ix86_legitimate_address_p (enum machine_mode mode ATTRIBUTE_UNUSED,
|
|
|
|
|
rtx addr, bool strict)
|
|
|
|
|
ix86_legitimate_address_p (enum machine_mode, rtx addr, bool strict)
|
|
|
|
|
{
|
|
|
|
|
struct ix86_address parts;
|
|
|
|
|
rtx base, index, disp;
|
|
|
|
@ -13825,8 +13815,7 @@ legitimize_pe_coff_symbol (rtx addr, bool inreg)
|
|
|
|
|
See comments by legitimize_pic_address in i386.c for details. */
|
|
|
|
|
|
|
|
|
|
static rtx
|
|
|
|
|
ix86_legitimize_address (rtx x, rtx oldx ATTRIBUTE_UNUSED,
|
|
|
|
|
enum machine_mode mode)
|
|
|
|
|
ix86_legitimize_address (rtx x, rtx, enum machine_mode mode)
|
|
|
|
|
{
|
|
|
|
|
int changed = 0;
|
|
|
|
|
unsigned log;
|
|
|
|
@ -14742,7 +14731,7 @@ print_reg (rtx x, int code, FILE *file)
|
|
|
|
|
pattern. */
|
|
|
|
|
|
|
|
|
|
static int
|
|
|
|
|
get_some_local_dynamic_name_1 (rtx *px, void *data ATTRIBUTE_UNUSED)
|
|
|
|
|
get_some_local_dynamic_name_1 (rtx *px, void *)
|
|
|
|
|
{
|
|
|
|
|
rtx x = *px;
|
|
|
|
|
|
|
|
|
@ -16068,7 +16057,7 @@ output_387_binary_op (rtx insn, rtx *operands)
|
|
|
|
|
/* Check if a 256bit AVX register is referenced inside of EXP. */
|
|
|
|
|
|
|
|
|
|
static int
|
|
|
|
|
ix86_check_avx256_register (rtx *pexp, void *data ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_check_avx256_register (rtx *pexp, void *)
|
|
|
|
|
{
|
|
|
|
|
rtx exp = *pexp;
|
|
|
|
|
|
|
|
|
@ -16196,7 +16185,7 @@ ix86_mode_needed (int entity, rtx insn)
|
|
|
|
|
/* Check if a 256bit AVX register is referenced in stores. */
|
|
|
|
|
|
|
|
|
|
static void
|
|
|
|
|
ix86_check_avx256_stores (rtx dest, const_rtx set ATTRIBUTE_UNUSED, void *data)
|
|
|
|
|
ix86_check_avx256_stores (rtx dest, const_rtx, void *data)
|
|
|
|
|
{
|
|
|
|
|
if (ix86_check_avx256_register (&dest, NULL))
|
|
|
|
|
{
|
|
|
|
@ -16324,7 +16313,7 @@ ix86_mode_exit (int entity)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static int
|
|
|
|
|
ix86_mode_priority (int entity ATTRIBUTE_UNUSED, int n)
|
|
|
|
|
ix86_mode_priority (int, int n)
|
|
|
|
|
{
|
|
|
|
|
return n;
|
|
|
|
|
}
|
|
|
|
@ -18577,8 +18566,8 @@ ix86_dep_by_shift_count (const_rtx set_insn, const_rtx use_insn)
|
|
|
|
|
appropriate constraints. */
|
|
|
|
|
|
|
|
|
|
bool
|
|
|
|
|
ix86_unary_operator_ok (enum rtx_code code ATTRIBUTE_UNUSED,
|
|
|
|
|
enum machine_mode mode ATTRIBUTE_UNUSED,
|
|
|
|
|
ix86_unary_operator_ok (enum rtx_code,
|
|
|
|
|
enum machine_mode,
|
|
|
|
|
rtx operands[2])
|
|
|
|
|
{
|
|
|
|
|
/* If one of operands is memory, source and destination must match. */
|
|
|
|
@ -18732,8 +18721,7 @@ ix86_expand_convert_uns_didf_sse (rtx target, rtx input)
|
|
|
|
|
|
|
|
|
|
/* Not used, but eases macroization of patterns. */
|
|
|
|
|
void
|
|
|
|
|
ix86_expand_convert_uns_sixf_sse (rtx target ATTRIBUTE_UNUSED,
|
|
|
|
|
rtx input ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_expand_convert_uns_sixf_sse (rtx, rtx)
|
|
|
|
|
{
|
|
|
|
|
gcc_unreachable ();
|
|
|
|
|
}
|
|
|
|
@ -19353,7 +19341,7 @@ ix86_expand_int_compare (enum rtx_code code, rtx op0, rtx op1)
|
|
|
|
|
Return the appropriate mode to use. */
|
|
|
|
|
|
|
|
|
|
enum machine_mode
|
|
|
|
|
ix86_fp_compare_mode (enum rtx_code code ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_fp_compare_mode (enum rtx_code)
|
|
|
|
|
{
|
|
|
|
|
/* ??? In order to make all comparisons reversible, we do all comparisons
|
|
|
|
|
non-trapping when compiling for IEEE. Once gcc is able to distinguish
|
|
|
|
@ -19568,7 +19556,7 @@ ix86_fp_comparison_cost (enum rtx_code code)
|
|
|
|
|
(2 bytes, vs. 3 for fnstsw+sahf and at least 5 for fnstsw+test). */
|
|
|
|
|
|
|
|
|
|
enum ix86_fpcmp_strategy
|
|
|
|
|
ix86_fp_comparison_strategy (enum rtx_code code ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_fp_comparison_strategy (enum rtx_code)
|
|
|
|
|
{
|
|
|
|
|
/* Do fcomi/sahf based test when profitable. */
|
|
|
|
|
|
|
|
|
@ -26531,9 +26519,7 @@ core2i7_first_cycle_multipass_fini (void *_data)
|
|
|
|
|
|
|
|
|
|
/* Prepare for scheduling pass. */
|
|
|
|
|
static void
|
|
|
|
|
ix86_sched_init_global (FILE *dump ATTRIBUTE_UNUSED,
|
|
|
|
|
int verbose ATTRIBUTE_UNUSED,
|
|
|
|
|
int max_uid ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_sched_init_global (FILE *, int, int)
|
|
|
|
|
{
|
|
|
|
|
/* Install scheduling hooks for current CPU. Some of these hooks are used
|
|
|
|
|
in time-critical parts of the scheduler, so we only set them up when
|
|
|
|
@ -32763,7 +32749,7 @@ ix86_init_builtins (void)
|
|
|
|
|
/* Return the ix86 builtin for CODE. */
|
|
|
|
|
|
|
|
|
|
static tree
|
|
|
|
|
ix86_builtin_decl (unsigned code, bool initialize_p ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_builtin_decl (unsigned code, bool)
|
|
|
|
|
{
|
|
|
|
|
if (code >= IX86_BUILTIN_MAX)
|
|
|
|
|
return error_mark_node;
|
|
|
|
@ -36915,8 +36901,7 @@ ix86_vectorize_builtin_gather (const_tree mem_vectype,
|
|
|
|
|
reciprocal of the function, or NULL_TREE if not available. */
|
|
|
|
|
|
|
|
|
|
static tree
|
|
|
|
|
ix86_builtin_reciprocal (unsigned int fn, bool md_fn,
|
|
|
|
|
bool sqrt ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_builtin_reciprocal (unsigned int fn, bool md_fn, bool)
|
|
|
|
|
{
|
|
|
|
|
if (! (TARGET_SSE_MATH && !optimize_insn_for_size_p ()
|
|
|
|
|
&& flag_finite_math_only && !flag_trapping_math
|
|
|
|
@ -38528,7 +38513,7 @@ x86_order_regs_for_local_alloc (void)
|
|
|
|
|
static tree
|
|
|
|
|
ix86_handle_callee_pop_aggregate_return (tree *node, tree name,
|
|
|
|
|
tree args,
|
|
|
|
|
int flags ATTRIBUTE_UNUSED,
|
|
|
|
|
int,
|
|
|
|
|
bool *no_add_attrs)
|
|
|
|
|
{
|
|
|
|
|
if (TREE_CODE (*node) != FUNCTION_TYPE
|
|
|
|
@ -38578,9 +38563,8 @@ ix86_handle_callee_pop_aggregate_return (tree *node, tree name,
|
|
|
|
|
/* Handle a "ms_abi" or "sysv" attribute; arguments as in
|
|
|
|
|
struct attribute_spec.handler. */
|
|
|
|
|
static tree
|
|
|
|
|
ix86_handle_abi_attribute (tree *node, tree name,
|
|
|
|
|
tree args ATTRIBUTE_UNUSED,
|
|
|
|
|
int flags ATTRIBUTE_UNUSED, bool *no_add_attrs)
|
|
|
|
|
ix86_handle_abi_attribute (tree *node, tree name, tree, int,
|
|
|
|
|
bool *no_add_attrs)
|
|
|
|
|
{
|
|
|
|
|
if (TREE_CODE (*node) != FUNCTION_TYPE
|
|
|
|
|
&& TREE_CODE (*node) != METHOD_TYPE
|
|
|
|
@ -38619,9 +38603,8 @@ ix86_handle_abi_attribute (tree *node, tree name,
|
|
|
|
|
/* Handle a "ms_struct" or "gcc_struct" attribute; arguments as in
|
|
|
|
|
struct attribute_spec.handler. */
|
|
|
|
|
static tree
|
|
|
|
|
ix86_handle_struct_attribute (tree *node, tree name,
|
|
|
|
|
tree args ATTRIBUTE_UNUSED,
|
|
|
|
|
int flags ATTRIBUTE_UNUSED, bool *no_add_attrs)
|
|
|
|
|
ix86_handle_struct_attribute (tree *node, tree name, tree, int,
|
|
|
|
|
bool *no_add_attrs)
|
|
|
|
|
{
|
|
|
|
|
tree *type = NULL;
|
|
|
|
|
if (DECL_P (*node))
|
|
|
|
@ -38653,9 +38636,8 @@ ix86_handle_struct_attribute (tree *node, tree name,
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static tree
|
|
|
|
|
ix86_handle_fndecl_attribute (tree *node, tree name,
|
|
|
|
|
tree args ATTRIBUTE_UNUSED,
|
|
|
|
|
int flags ATTRIBUTE_UNUSED, bool *no_add_attrs)
|
|
|
|
|
ix86_handle_fndecl_attribute (tree *node, tree name, tree, int,
|
|
|
|
|
bool *no_add_attrs)
|
|
|
|
|
{
|
|
|
|
|
if (TREE_CODE (*node) != FUNCTION_DECL)
|
|
|
|
|
{
|
|
|
|
@ -38733,9 +38715,8 @@ x86_this_parameter (tree function)
|
|
|
|
|
/* Determine whether x86_output_mi_thunk can succeed. */
|
|
|
|
|
|
|
|
|
|
static bool
|
|
|
|
|
x86_can_output_mi_thunk (const_tree thunk ATTRIBUTE_UNUSED,
|
|
|
|
|
HOST_WIDE_INT delta ATTRIBUTE_UNUSED,
|
|
|
|
|
HOST_WIDE_INT vcall_offset, const_tree function)
|
|
|
|
|
x86_can_output_mi_thunk (const_tree, HOST_WIDE_INT, HOST_WIDE_INT vcall_offset,
|
|
|
|
|
const_tree function)
|
|
|
|
|
{
|
|
|
|
|
/* 64-bit can handle anything. */
|
|
|
|
|
if (TARGET_64BIT)
|
|
|
|
@ -38764,8 +38745,7 @@ x86_can_output_mi_thunk (const_tree thunk ATTRIBUTE_UNUSED,
|
|
|
|
|
*(*this + vcall_offset) should be added to THIS. */
|
|
|
|
|
|
|
|
|
|
static void
|
|
|
|
|
x86_output_mi_thunk (FILE *file,
|
|
|
|
|
tree thunk ATTRIBUTE_UNUSED, HOST_WIDE_INT delta,
|
|
|
|
|
x86_output_mi_thunk (FILE *file, tree, HOST_WIDE_INT delta,
|
|
|
|
|
HOST_WIDE_INT vcall_offset, tree function)
|
|
|
|
|
{
|
|
|
|
|
rtx this_param = x86_this_parameter (function);
|
|
|
|
@ -39419,7 +39399,7 @@ x86_extended_QIreg_mentioned_p (rtx insn)
|
|
|
|
|
/* Return nonzero when P points to register encoded via REX prefix.
|
|
|
|
|
Called via for_each_rtx. */
|
|
|
|
|
static int
|
|
|
|
|
extended_reg_mentioned_1 (rtx *p, void *data ATTRIBUTE_UNUSED)
|
|
|
|
|
extended_reg_mentioned_1 (rtx *p, void *)
|
|
|
|
|
{
|
|
|
|
|
unsigned int regno;
|
|
|
|
|
if (!REG_P (*p))
|
|
|
|
@ -41165,9 +41145,7 @@ ix86_c_mode_for_suffix (char suffix)
|
|
|
|
|
with the old cc0-based compiler. */
|
|
|
|
|
|
|
|
|
|
static tree
|
|
|
|
|
ix86_md_asm_clobbers (tree outputs ATTRIBUTE_UNUSED,
|
|
|
|
|
tree inputs ATTRIBUTE_UNUSED,
|
|
|
|
|
tree clobbers)
|
|
|
|
|
ix86_md_asm_clobbers (tree, tree, tree clobbers)
|
|
|
|
|
{
|
|
|
|
|
clobbers = tree_cons (NULL_TREE, build_string (5, "flags"),
|
|
|
|
|
clobbers);
|
|
|
|
@ -42374,8 +42352,7 @@ static const struct attribute_spec ix86_attribute_table[] =
|
|
|
|
|
/* Implement targetm.vectorize.builtin_vectorization_cost. */
|
|
|
|
|
static int
|
|
|
|
|
ix86_builtin_vectorization_cost (enum vect_cost_for_stmt type_of_cost,
|
|
|
|
|
tree vectype,
|
|
|
|
|
int misalign ATTRIBUTE_UNUSED)
|
|
|
|
|
tree vectype, int)
|
|
|
|
|
{
|
|
|
|
|
unsigned elements;
|
|
|
|
|
|
|
|
|
@ -46421,8 +46398,7 @@ has_dispatch (rtx insn, int action)
|
|
|
|
|
enabled for other processors. */
|
|
|
|
|
|
|
|
|
|
static int
|
|
|
|
|
ix86_reassociation_width (unsigned int opc ATTRIBUTE_UNUSED,
|
|
|
|
|
enum machine_mode mode)
|
|
|
|
|
ix86_reassociation_width (unsigned int, enum machine_mode mode)
|
|
|
|
|
{
|
|
|
|
|
int res = 1;
|
|
|
|
|
|
|
|
|
@ -46519,7 +46495,7 @@ ix86_spill_class (reg_class_t rclass, enum machine_mode mode)
|
|
|
|
|
/* Implement targetm.vectorize.init_cost. */
|
|
|
|
|
|
|
|
|
|
static void *
|
|
|
|
|
ix86_init_cost (struct loop *loop_info ATTRIBUTE_UNUSED)
|
|
|
|
|
ix86_init_cost (struct loop *)
|
|
|
|
|
{
|
|
|
|
|
unsigned *cost = XNEWVEC (unsigned, 3);
|
|
|
|
|
cost[vect_prologue] = cost[vect_body] = cost[vect_epilogue] = 0;
|
|
|
|
|