diff options
author | Kai Tietz <kai.tietz@onevision.com> | 2008-05-08 09:10:49 +0200 |
---|---|---|
committer | Kai Tietz <ktietz@gcc.gnu.org> | 2008-05-08 09:10:49 +0200 |
commit | 81464b2cd8f8153d1314a628fdc3dbdbb27a9c02 (patch) | |
tree | 83a184beafd987a7fefd927cf5a86a9415fcc4c4 /gcc/config | |
parent | 2fada7f3f32accc658153f57035890255a126076 (diff) | |
download | gcc-81464b2cd8f8153d1314a628fdc3dbdbb27a9c02.zip gcc-81464b2cd8f8153d1314a628fdc3dbdbb27a9c02.tar.gz gcc-81464b2cd8f8153d1314a628fdc3dbdbb27a9c02.tar.bz2 |
2008-05-07 Kai Tietz <kai,tietz@onevision.com>
* calls.c (compute_argument_block_size): Add argument tree fndecl.
(OUTGOING_REG_PARM_STACK_SPACE): Add function type argument.
(emit_library_call_value_1): Add new variable fndecl initialized by
NULL_TREE. It should be the decl type of orgfun, but this information
seems not to be available here, so it uses the default calling abi.
* config/arm/arm.c (arm_return_in_memory): Add fntype argumen.
* config/arm/arm.h (RETURN_IN_MEMORY): Replace RETURN_IN_MEMORY
by TARGET_RETURN_IN_MEMORY.
* config/i386/i386-interix.h: Likewise.
* config/i386/i386.h: Likewise.
* config/i386/i386elf.h: Likewise.
* config/i386/ptx4-i.h: Likewise.
* config/i386/sol2-10.h: Likewise.
* config/i386/sysv4.h: Likewise.
* config/i386/vx-common.h: Likewise.
* config/cris/cris.h: Removed #if 0 clause.
* config/arm/arm-protos.h (arm_return_in_memory): Add fntype
argument.
* config/i386/i386-protos.h (ix86_return_in_memory): Add fntype
argument.
(ix86_sol10_return_in_memory): Likewise.
(ix86_i386elf_return_in_memory): New.
(ix86_i386interix_return_in_memory): New.
* config/mt/mt-protos.h (mt_return_in_memory): New.
* config/mt/mt.c: Likewise.
* config/mt/mt.h (OUTGOING_REG_PARM_STACK_SPACE): Add FNTYPE argument.
(RETURN_IN_MEMORY): Replace by TARGET_RETURN_IN_MEMORY.
* config/bfin/bfin.h: Likewise.
* config/bfin/bfin-protos.h (bfin_return_in_memory): Add fntype
argument.
* config/bfin/bfin.c: Likewise.
* config/pa/pa.h (OUTGOING_REG_PARM_STACK_SPACE): Add FNTYPE argument.
* config/alpha/unicosmk.h: Likewise.
* config/i386/cygming.h: Likewise.
* config/iq2000/iq2000.h: Likewise.
* config/mips/mips.h: Likewise.
* config/mn10300/mn10300.h: Likewise.
* config/rs6000/rs6000.h: Likewise.
* config/score/score.h: Likewise.
* config/spu/spu.h: Likewise.
* config/v850/v850.h: Likewise.
* defaults.h: Likewise.
* doc/tm.texi (OUTGOING_REG_PARM_STACK_SPACE): Adjust documentation.
* expr.c (emit_block_move): Adjust use of OUTGOING_REG_PARM_STACK_SPACE.
* function.c (STACK_DYNAMIC_OFFSET): Adjust use of
OUTGOING_REG_PARM_STACK_SPACE.
* targhooks.c (default_return_in_memory): Remove RETURN_IN_MEMORY.
From-SVN: r135069
Diffstat (limited to 'gcc/config')
31 files changed, 67 insertions, 61 deletions
diff --git a/gcc/config/alpha/unicosmk.h b/gcc/config/alpha/unicosmk.h index d08fa73..4a24bd5 100644 --- a/gcc/config/alpha/unicosmk.h +++ b/gcc/config/alpha/unicosmk.h @@ -115,7 +115,7 @@ along with GCC; see the file COPYING3. If not see in registers) are allocated. */ #define REG_PARM_STACK_SPACE(DECL) 48 -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 /* If an argument can't be passed in registers even though not all argument registers have been used yet, it is passed on the stack in the space diff --git a/gcc/config/arm/arm-protos.h b/gcc/config/arm/arm-protos.h index 3a71744..e4540ec 100644 --- a/gcc/config/arm/arm-protos.h +++ b/gcc/config/arm/arm-protos.h @@ -43,7 +43,7 @@ extern void arm_output_fn_unwind (FILE *, bool); #ifdef TREE_CODE -extern int arm_return_in_memory (const_tree); +extern int arm_return_in_memory (const_tree, const_tree); #endif #ifdef RTX_CODE extern bool arm_vector_mode_supported_p (enum machine_mode); diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c index 64f12a1..3a81172 100644 --- a/gcc/config/arm/arm.c +++ b/gcc/config/arm/arm.c @@ -2736,9 +2736,9 @@ arm_apply_result_size (void) /* Decide whether a type should be returned in memory (true) or in a register (false). This is called by the macro - RETURN_IN_MEMORY. */ + TARGET_RETURN_IN_MEMORY. */ int -arm_return_in_memory (const_tree type) +arm_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) { HOST_WIDE_INT size; @@ -2801,7 +2801,7 @@ arm_return_in_memory (const_tree type) /* ... Aggregates that are not themselves valid for returning in a register are not allowed. */ - if (RETURN_IN_MEMORY (TREE_TYPE (field))) + if (arm_return_in_memory (TREE_TYPE (field), NULL_TREE)) return 1; /* Now check the remaining fields, if any. Only bitfields are allowed, @@ -2836,7 +2836,7 @@ arm_return_in_memory (const_tree type) if (FLOAT_TYPE_P (TREE_TYPE (field))) return 1; - if (RETURN_IN_MEMORY (TREE_TYPE (field))) + if (arm_return_in_memory (TREE_TYPE (field), NULL_TREE)) return 1; } diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h index b6e182c..7f10a57 100644 --- a/gcc/config/arm/arm.h +++ b/gcc/config/arm/arm.h @@ -1481,7 +1481,7 @@ do { \ /* How large values are returned */ /* A C expression which can inhibit the returning of certain function values in registers, based on the type of value. */ -#define RETURN_IN_MEMORY(TYPE) arm_return_in_memory (TYPE) +#define TARGET_RETURN_IN_MEMORY arm_return_in_memory /* Define DEFAULT_PCC_STRUCT_RETURN to 1 if all structure and union return values must be in memory. On the ARM, they need only do so if larger diff --git a/gcc/config/arm/netbsd.h b/gcc/config/arm/netbsd.h index 33833cc..d9d39bd 100644 --- a/gcc/config/arm/netbsd.h +++ b/gcc/config/arm/netbsd.h @@ -101,7 +101,7 @@ /* Although not normally relevant (since by default, all aggregates are returned in memory) compiling some parts of libc requires non-APCS style struct returns. */ -#undef RETURN_IN_MEMORY +#undef TARGET_RETURN_IN_MEMORY /* VERY BIG NOTE : Change of structure alignment for RiscBSD. There are consequences you should be aware of... diff --git a/gcc/config/bfin/bfin-protos.h b/gcc/config/bfin/bfin-protos.h index 1786f5c..1dc46f7 100644 --- a/gcc/config/bfin/bfin-protos.h +++ b/gcc/config/bfin/bfin-protos.h @@ -120,7 +120,7 @@ extern void asm_conditional_branch (rtx, rtx *, int, int); extern rtx bfin_gen_compare (rtx, Mmode); extern int bfin_local_alignment (tree, int); -extern int bfin_return_in_memory (const_tree); +extern int bfin_return_in_memory (const_tree, const_tree); extern void initialize_trampoline (rtx, rtx, rtx); extern bool bfin_legitimate_address_p (Mmode, rtx, int); extern rtx bfin_va_arg (tree, tree); diff --git a/gcc/config/bfin/bfin.c b/gcc/config/bfin/bfin.c index 87a1d93..e4c3f0c 100644 --- a/gcc/config/bfin/bfin.c +++ b/gcc/config/bfin/bfin.c @@ -1840,10 +1840,10 @@ bfin_pass_by_reference (CUMULATIVE_ARGS *cum ATTRIBUTE_UNUSED, /* Decide whether a type should be returned in memory (true) or in a register (false). This is called by the macro - RETURN_IN_MEMORY. */ + TARGET_RETURN_IN_MEMORY. */ int -bfin_return_in_memory (const_tree type) +bfin_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) { int size = int_size_in_bytes (type); return size > 2 * UNITS_PER_WORD || size == -1; diff --git a/gcc/config/bfin/bfin.h b/gcc/config/bfin/bfin.h index 3850c62..55a6b7d 100644 --- a/gcc/config/bfin/bfin.h +++ b/gcc/config/bfin/bfin.h @@ -283,7 +283,7 @@ extern const char *bfin_library_id_string; /* Define this if the above stack space is to be considered part of the * space allocated by the caller. */ -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 /* Define this if the maximum size of all the outgoing args is to be accumulated and pushed during the prologue. The amount can be @@ -841,7 +841,7 @@ typedef struct { #define FUNCTION_VALUE_REGNO_P(N) ((N) == REG_R0) #define DEFAULT_PCC_STRUCT_RETURN 0 -#define RETURN_IN_MEMORY(TYPE) bfin_return_in_memory(TYPE) +#define TARGET_RETURN_IN_MEMORY bfin_return_in_memory /* Before the prologue, the return address is in the RETS register. */ #define INCOMING_RETURN_ADDR_RTX gen_rtx_REG (Pmode, REG_RETS) diff --git a/gcc/config/cris/cris.h b/gcc/config/cris/cris.h index b8f4ae5..915c314 100644 --- a/gcc/config/cris/cris.h +++ b/gcc/config/cris/cris.h @@ -923,14 +923,6 @@ struct cum_args {int regs;}; /* Node: Aggregate Return */ -#if 0 -/* FIXME: Let's try this some time, so we return structures in registers. - We would cast the result of int_size_in_bytes to unsigned, so we will - get a huge number for "structures" of variable size (-1). */ -#define RETURN_IN_MEMORY(TYPE) \ - ((unsigned) int_size_in_bytes (TYPE) > CRIS_MAX_ARGS_IN_REGS * UNITS_PER_WORD) -#endif - #define CRIS_STRUCT_VALUE_REGNUM ((CRIS_FIRST_ARG_REG) - 1) diff --git a/gcc/config/fr30/fr30.h b/gcc/config/fr30/fr30.h index 0f7592d..95bdcc3 100644 --- a/gcc/config/fr30/fr30.h +++ b/gcc/config/fr30/fr30.h @@ -726,7 +726,7 @@ enum reg_class in memory. Since this results in slower code, this should be defined only if needed for compatibility with other compilers or with an ABI. If you define this macro to be 0, then the conventions used for structure and union - return values are decided by the `RETURN_IN_MEMORY' macro. + return values are decided by the `TARGET_RETURN_IN_MEMORY' macro. If not defined, this defaults to the value 1. */ #define DEFAULT_PCC_STRUCT_RETURN 1 diff --git a/gcc/config/i386/cygming.h b/gcc/config/i386/cygming.h index 65311da..a6537bc 100644 --- a/gcc/config/i386/cygming.h +++ b/gcc/config/i386/cygming.h @@ -127,7 +127,7 @@ along with GCC; see the file COPYING3. If not see #define REG_PARM_STACK_SPACE(FNDECL) (TARGET_64BIT_MS_ABI ? 32 : 0) #undef OUTGOING_REG_PARM_STACK_SPACE -#define OUTGOING_REG_PARM_STACK_SPACE (TARGET_64BIT_MS_ABI ? 1 : 0) +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) (TARGET_64BIT_MS_ABI ? 1 : 0) #undef REGPARM_MAX #define REGPARM_MAX (TARGET_64BIT_MS_ABI ? 4 : 3) diff --git a/gcc/config/i386/i386-interix.h b/gcc/config/i386/i386-interix.h index 7015360..74e2892 100644 --- a/gcc/config/i386/i386-interix.h +++ b/gcc/config/i386/i386-interix.h @@ -357,7 +357,5 @@ extern void i386_pe_unique_section (tree, int); #define DEFAULT_PCC_STRUCT_RETURN 0 -#undef RETURN_IN_MEMORY -#define RETURN_IN_MEMORY(TYPE) \ - (TYPE_MODE (TYPE) == BLKmode || \ - (AGGREGATE_TYPE_P (TYPE) && int_size_in_bytes(TYPE) > 8 )) +#undef TARGET_RETURN_IN_MEMORY +#define TARGET_RETURN_IN_MEMORY ix86_i386interix_return_in_memory diff --git a/gcc/config/i386/i386-protos.h b/gcc/config/i386/i386-protos.h index 369953f..fd2e3c7 100644 --- a/gcc/config/i386/i386-protos.h +++ b/gcc/config/i386/i386-protos.h @@ -134,9 +134,10 @@ extern rtx ix86_libcall_value (enum machine_mode); extern bool ix86_function_value_regno_p (int); extern bool ix86_function_arg_regno_p (int); extern int ix86_function_arg_boundary (enum machine_mode, tree); -extern int ix86_return_in_memory (const_tree); -extern int ix86_sol10_return_in_memory (const_tree); - +extern int ix86_return_in_memory (const_tree, const_tree); +extern int ix86_sol10_return_in_memory (const_tree,const_tree); +extern int ix86_i386elf_return_in_memory (const_tree,const_tree); +extern int ix86_i386interix_return_in_memory (const_tree,const_tree); extern rtx ix86_force_to_memory (enum machine_mode, rtx); extern void ix86_free_from_memory (enum machine_mode); extern void ix86_split_fp_branch (enum rtx_code code, rtx, rtx, diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 7d254fe..0cb337f 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -4902,7 +4902,7 @@ return_in_memory_ms_64 (const_tree type, enum machine_mode mode) } int -ix86_return_in_memory (const_tree type) +ix86_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) { const enum machine_mode mode = type_natural_mode (type); @@ -4920,7 +4920,7 @@ ix86_return_in_memory (const_tree type) are returned in memory, rather than in MMX registers. */ int -ix86_sol10_return_in_memory (const_tree type) +ix86_sol10_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) { int size; enum machine_mode mode = type_natural_mode (type); @@ -4951,6 +4951,20 @@ ix86_sol10_return_in_memory (const_tree type) return size > 12; } +int +ix86_i386elf_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) +{ + return (TYPE_MODE (type) == BLKmode + || (VECTOR_MODE_P (TYPE_MODE (type)) && int_size_in_bytes (type) == 8)); +} + +int +ix86_i386interix_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) +{ + return (TYPE_MODE (type) == BLKmode + || (AGGREGATE_TYPE_P (type) && int_size_in_bytes(type) > 8 )); +} + /* When returning SSE vector types, we have a choice of either (1) being abi incompatible with a -march switch, or (2) generating an error. @@ -4959,7 +4973,7 @@ ix86_sol10_return_in_memory (const_tree type) Choose the STRUCT_VALUE_RTX hook because that's (at present) only called in response to actually generating a caller or callee that - uses such a type. As opposed to RETURN_IN_MEMORY, which is called + uses such a type. As opposed to TARGET_RETURN_IN_MEMORY, which is called via aggregate_value_p for general type probing from tree-ssa. */ static rtx diff --git a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h index bb6fa18..87815ed 100644 --- a/gcc/config/i386/i386.h +++ b/gcc/config/i386/i386.h @@ -1278,8 +1278,7 @@ do { \ should always be returned in memory. You should instead use `DEFAULT_PCC_STRUCT_RETURN' to indicate this. */ -#define RETURN_IN_MEMORY(TYPE) \ - ix86_return_in_memory (TYPE) +#define TARGET_RETURN_IN_MEMORY ix86_return_in_memory /* This is overridden by <cygwin.h>. */ #define MS_AGGREGATE_RETURN 0 diff --git a/gcc/config/i386/i386elf.h b/gcc/config/i386/i386elf.h index cd42f88..6659669 100644 --- a/gcc/config/i386/i386elf.h +++ b/gcc/config/i386/i386elf.h @@ -29,10 +29,8 @@ along with GCC; see the file COPYING3. If not see /* The ELF ABI for the i386 says that records and unions are returned in memory. */ -#undef RETURN_IN_MEMORY -#define RETURN_IN_MEMORY(TYPE) \ - (TYPE_MODE (TYPE) == BLKmode \ - || (VECTOR_MODE_P (TYPE_MODE (TYPE)) && int_size_in_bytes (TYPE) == 8)) +#undef TARGET_RETURN_IN_MEMORY +#define TARGET_RETURN_IN_MEMORY ix86_i386elf_return_in_memory #undef CPP_SPEC #define CPP_SPEC "" diff --git a/gcc/config/i386/ptx4-i.h b/gcc/config/i386/ptx4-i.h index 3c46e6a..08473f0 100644 --- a/gcc/config/i386/ptx4-i.h +++ b/gcc/config/i386/ptx4-i.h @@ -27,10 +27,8 @@ along with GCC; see the file COPYING3. If not see /* The svr4 ABI for the i386 says that records and unions are returned in memory. */ -#undef RETURN_IN_MEMORY -#define RETURN_IN_MEMORY(TYPE) \ - (TYPE_MODE (TYPE) == BLKmode \ - || (VECTOR_MODE_P (TYPE_MODE (TYPE)) && int_size_in_bytes (TYPE) == 8)) +#undef TARGET_RETURN_IN_MEMORY +#define TARGET_RETURN_IN_MEMORY ix86_i386elf_return_in_memory #define TARGET_OS_CPP_BUILTINS() \ do \ diff --git a/gcc/config/i386/sol2-10.h b/gcc/config/i386/sol2-10.h index 92e2c6c..88b92f6 100644 --- a/gcc/config/i386/sol2-10.h +++ b/gcc/config/i386/sol2-10.h @@ -110,5 +110,5 @@ along with GCC; see the file COPYING3. If not see #undef TARGET_ASM_NAMED_SECTION #define TARGET_ASM_NAMED_SECTION i386_solaris_elf_named_section -#undef RETURN_IN_MEMORY -#define RETURN_IN_MEMORY ix86_sol10_return_in_memory +#undef TARGET_RETURN_IN_MEMORY +#define TARGET_RETURN_IN_MEMORY ix86_sol10_return_in_memory diff --git a/gcc/config/i386/sysv4.h b/gcc/config/i386/sysv4.h index e105272..e57fd0c 100644 --- a/gcc/config/i386/sysv4.h +++ b/gcc/config/i386/sysv4.h @@ -25,10 +25,8 @@ along with GCC; see the file COPYING3. If not see /* The svr4 ABI for the i386 says that records and unions are returned in memory. */ -#undef RETURN_IN_MEMORY -#define RETURN_IN_MEMORY(TYPE) \ - (TYPE_MODE (TYPE) == BLKmode \ - || (VECTOR_MODE_P (TYPE_MODE (TYPE)) && int_size_in_bytes (TYPE) == 8)) +#undef TARGET_RETURN_IN_MEMORY +#define TARGET_RETURN_IN_MEMORY ix86_i386elf_return_in_memory /* Output at beginning of assembler file. */ /* The .file command should always begin the output. */ diff --git a/gcc/config/i386/vx-common.h b/gcc/config/i386/vx-common.h index 2544189..81530bc 100644 --- a/gcc/config/i386/vx-common.h +++ b/gcc/config/i386/vx-common.h @@ -22,5 +22,5 @@ along with GCC; see the file COPYING3. If not see /* VxWorks uses the same ABI as Solaris 10. */ -#undef RETURN_IN_MEMORY -#define RETURN_IN_MEMORY ix86_sol10_return_in_memory +#undef TARGET_RETURN_IN_MEMORY +#define TARGET_RETURN_IN_MEMORY ix86_sol10_return_in_memory diff --git a/gcc/config/iq2000/iq2000.h b/gcc/config/iq2000/iq2000.h index cdbf5a2..f5574e4 100644 --- a/gcc/config/iq2000/iq2000.h +++ b/gcc/config/iq2000/iq2000.h @@ -374,7 +374,7 @@ enum reg_class #define REG_PARM_STACK_SPACE(FNDECL) 0 -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 #define RETURN_POPS_ARGS(FUNDECL,FUNTYPE,SIZE) 0 diff --git a/gcc/config/mips/mips.h b/gcc/config/mips/mips.h index cda433a..1391c99 100644 --- a/gcc/config/mips/mips.h +++ b/gcc/config/mips/mips.h @@ -1936,7 +1936,7 @@ enum reg_class If `ACCUMULATE_OUTGOING_ARGS' is also defined, the only effect of this macro is to determine whether the space is included in `crtl->outgoing_args_size'. */ -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 #define STACK_BOUNDARY (TARGET_NEWABI ? 128 : 64) diff --git a/gcc/config/mn10300/mn10300.h b/gcc/config/mn10300/mn10300.h index 8242275..1d2339b 100644 --- a/gcc/config/mn10300/mn10300.h +++ b/gcc/config/mn10300/mn10300.h @@ -486,7 +486,7 @@ enum reg_class { /* We use d0/d1 for passing parameters, so allocate 8 bytes of space for a register flushback area. */ #define REG_PARM_STACK_SPACE(DECL) 8 -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 #define ACCUMULATE_OUTGOING_ARGS 1 /* So we can allocate space for return pointers once for the function diff --git a/gcc/config/mt/mt-protos.h b/gcc/config/mt/mt-protos.h index 99717dc..2dcb945 100644 --- a/gcc/config/mt/mt-protos.h +++ b/gcc/config/mt/mt-protos.h @@ -31,6 +31,7 @@ extern void mt_add_loop (void); extern const char * mt_cannot_inline_p (tree); extern int mt_function_arg_boundary (enum machine_mode, tree); extern void mt_function_arg_advance (CUMULATIVE_ARGS *, enum machine_mode, tree, int); +extern int mt_return_in_memory (const_tree,const_tree); #endif #ifdef RTX_CODE diff --git a/gcc/config/mt/mt.c b/gcc/config/mt/mt.c index 272e028..c7fc0d1 100644 --- a/gcc/config/mt/mt.c +++ b/gcc/config/mt/mt.c @@ -2460,6 +2460,13 @@ mt_machine_reorg (void) mt_reorg_hazard (); } } + +int +mt_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) +{ + return (int_size_in_bytes (type) > UNITS_PER_WORD); +} + /* Initialize the GCC target structure. */ const struct attribute_spec mt_attribute_table[]; diff --git a/gcc/config/mt/mt.h b/gcc/config/mt/mt.h index de20d40..b587326 100644 --- a/gcc/config/mt/mt.h +++ b/gcc/config/mt/mt.h @@ -532,7 +532,7 @@ extern struct mt_frame_info current_frame_info; /* Define this if it is the responsibility of the caller to allocate the area reserved for arguments passed in registers. */ -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 /* The number of register assigned to holding function arguments. */ #define MT_NUM_ARG_REGS 4 @@ -580,7 +580,7 @@ extern struct mt_frame_info current_frame_info; /* A C expression which can inhibit the returning of certain function values in registers, based on the type of value. */ -#define RETURN_IN_MEMORY(TYPE) (int_size_in_bytes (TYPE) > UNITS_PER_WORD) +#define TARGET_RETURN_IN_MEMORY mt_return_in_memory /* Define this macro to be 1 if all structure and union return values must be in memory. */ diff --git a/gcc/config/pa/pa.h b/gcc/config/pa/pa.h index 541f2e3..22cd9f3 100644 --- a/gcc/config/pa/pa.h +++ b/gcc/config/pa/pa.h @@ -549,7 +549,7 @@ extern struct rtx_def *hppa_pic_save_rtx (void); /* Define this if the above stack space is to be considered part of the space allocated by the caller. */ -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 /* Keep the stack pointer constant throughout the function. This is both an optimization and a necessity: longjmp diff --git a/gcc/config/rs6000/rs6000.h b/gcc/config/rs6000/rs6000.h index 1bde282..7ec3d94 100644 --- a/gcc/config/rs6000/rs6000.h +++ b/gcc/config/rs6000/rs6000.h @@ -1327,7 +1327,7 @@ extern enum rs6000_abi rs6000_current_abi; /* available for use by subtarget */ /* Define this if the above stack space is to be considered part of the space allocated by the caller. */ -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 /* This is the difference between the logical top of stack and the actual sp. diff --git a/gcc/config/score/score.h b/gcc/config/score/score.h index fe6e6f9..78d2c57 100644 --- a/gcc/config/score/score.h +++ b/gcc/config/score/score.h @@ -579,7 +579,7 @@ extern enum reg_class score_char_to_class[256]; If `ACCUMULATE_OUTGOING_ARGS' is also defined, the only effect of this macro is to determine whether the space is included in `crtl->outgoing_args_size'. */ -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 #define RETURN_POPS_ARGS(FUNDECL, FUNTYPE, STACK_SIZE) 0 diff --git a/gcc/config/spu/spu.h b/gcc/config/spu/spu.h index 3d038ca..729e0d7 100644 --- a/gcc/config/spu/spu.h +++ b/gcc/config/spu/spu.h @@ -353,7 +353,7 @@ targetm.resolve_overloaded_builtin = spu_resolve_overloaded_builtin; \ #define REG_PARM_STACK_SPACE(FNDECL) 0 -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 #define RETURN_POPS_ARGS(FUNDECL,FUNTYPE,SIZE) (0) diff --git a/gcc/config/v850/v850.h b/gcc/config/v850/v850.h index 50119c2..b951b2c 100644 --- a/gcc/config/v850/v850.h +++ b/gcc/config/v850/v850.h @@ -625,7 +625,7 @@ struct cum_arg { int nbytes; int anonymous_args; }; /* Define this if the above stack space is to be considered part of the space allocated by the caller. */ -#define OUTGOING_REG_PARM_STACK_SPACE 1 +#define OUTGOING_REG_PARM_STACK_SPACE(FNTYPE) 1 /* 1 if N is a possible register number for function argument passing. */ |