From 23668cf768bd439b04610ead2d124fcaa73f1828 Mon Sep 17 00:00:00 2001 From: Chung-Lin Tang Date: Thu, 19 Jun 2008 02:51:26 +0000 Subject: arm-protos.h (arm_return_in_memory): Remove public arm_return_in_memory() prototype. * arm-protos.h (arm_return_in_memory): Remove public arm_return_in_memory() prototype. * arm.c (arm_return_in_memory): Add static prototype, add target hook macro, change definition and comments. * arm.h (TARGET_RETURN_IN_MEMORY): Remove. From-SVN: r136934 --- gcc/ChangeLog | 8 ++++++++ gcc/config/arm/arm-protos.h | 3 --- gcc/config/arm/arm.c | 8 ++++++-- gcc/config/arm/arm.h | 5 ----- 4 files changed, 14 insertions(+), 10 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9d5e933..e5bbef9 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2008-06-16 Chung-Lin Tang + + * arm-protos.h (arm_return_in_memory): Remove public + arm_return_in_memory() prototype. + * arm.c (arm_return_in_memory): Add static prototype, add target + hook macro, change definition and comments. + * arm.h (TARGET_RETURN_IN_MEMORY): Remove. + 2008-06-19 Ben Elliston * dfp.h, dfp.c, config/dfp-bit.h, config/dfp-bit.c, real.h, diff --git a/gcc/config/arm/arm-protos.h b/gcc/config/arm/arm-protos.h index 1dbd3a1..a296349 100644 --- a/gcc/config/arm/arm-protos.h +++ b/gcc/config/arm/arm-protos.h @@ -42,9 +42,6 @@ extern unsigned int arm_dbx_register_number (unsigned int); extern void arm_output_fn_unwind (FILE *, bool); -#ifdef TREE_CODE -extern bool arm_return_in_memory (const_tree, const_tree); -#endif #ifdef RTX_CODE extern bool arm_vector_mode_supported_p (enum machine_mode); extern int arm_hard_regno_mode_ok (unsigned int, enum machine_mode); diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c index 5df6a77..c7f223a 100644 --- a/gcc/config/arm/arm.c +++ b/gcc/config/arm/arm.c @@ -166,6 +166,7 @@ static bool arm_default_short_enums (void); static bool arm_align_anon_bitfield (void); static bool arm_return_in_msb (const_tree); static bool arm_must_pass_in_stack (enum machine_mode, const_tree); +static bool arm_return_in_memory (const_tree, const_tree); #ifdef TARGET_UNWIND_INFO static void arm_unwind_emit (FILE *, rtx); static bool arm_output_ttype (rtx); @@ -333,6 +334,9 @@ static bool arm_allocate_stack_slots_for_args (void); #undef TARGET_RETURN_IN_MSB #define TARGET_RETURN_IN_MSB arm_return_in_msb +#undef TARGET_RETURN_IN_MEMORY +#define TARGET_RETURN_IN_MEMORY arm_return_in_memory + #undef TARGET_MUST_PASS_IN_STACK #define TARGET_MUST_PASS_IN_STACK arm_must_pass_in_stack @@ -2747,9 +2751,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 + or in a register (false). This is called as the target hook TARGET_RETURN_IN_MEMORY. */ -bool +static bool arm_return_in_memory (const_tree type, const_tree fntype ATTRIBUTE_UNUSED) { HOST_WIDE_INT size; diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h index b77a2ac..9f662f3 100644 --- a/gcc/config/arm/arm.h +++ b/gcc/config/arm/arm.h @@ -1478,11 +1478,6 @@ do { \ registers. */ #define APPLY_RESULT_SIZE arm_apply_result_size() -/* 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 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 than a word, or if they contain elements offset from zero in the struct. */ -- cgit v1.1