(frv_trampoline_init): Rename from frv_initialize_trampoline;
make static, adjust arguments for TARGET_TRAMPOLINE_INIT hook.
* config/frv/frv.h (INITIALIZE_TRAMPOLINE): Remove.
* config/frv/frv-protos.h (frv_initialize_trampoline): Remove.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@151992
138bc75d-0d04-0410-961f-
82ee72b054a4
(INITIALIZE_TRAMPOLINE): Move code to fr30_trampoline_init;
adjust for target hook parameters.
+ * config/frv/frv.c (TARGET_TRAMPOLINE_INIT): New.
+ (frv_trampoline_init): Rename from frv_initialize_trampoline;
+ make static, adjust arguments for TARGET_TRAMPOLINE_INIT hook.
+ * config/frv/frv.h (INITIALIZE_TRAMPOLINE): Remove.
+ * config/frv/frv-protos.h (frv_initialize_trampoline): Remove.
+
2009-09-22 Jakub Jelinek <jakub@redhat.com>
* config/rs6000/rs6000.c (bdesc_2arg): Fix CODE_FOR_vector_gt* codes
extern void frv_ifcvt_modify_cancel (ce_if_block_t *);
#endif
extern int frv_trampoline_size (void);
-extern void frv_initialize_trampoline (rtx, rtx, rtx);
extern enum reg_class frv_secondary_reload_class
(enum reg_class,
enum machine_mode, rtx);
secondary_reload_info *);
static bool frv_frame_pointer_required (void);
static bool frv_can_eliminate (const int, const int);
+static void frv_trampoline_init (rtx, tree, rtx);
\f
/* Allow us to easily change the default for -malloc-cc. */
#ifndef DEFAULT_NO_ALLOC_CC
#undef TARGET_CAN_ELIMINATE
#define TARGET_CAN_ELIMINATE frv_can_eliminate
+#undef TARGET_TRAMPOLINE_INIT
+#define TARGET_TRAMPOLINE_INIT frv_trampoline_init
+
struct gcc_target targetm = TARGET_INITIALIZER;
#define FRV_SYMBOL_REF_TLS_P(RTX) \
sethi #0, <static_chain>
jmpl @(gr0,<jmp_reg>) */
-void
-frv_initialize_trampoline (rtx addr, rtx fnaddr, rtx static_chain)
+static void
+frv_trampoline_init (rtx m_tramp, tree fndecl, rtx static_chain)
{
+ rtx addr = XEXP (m_tramp, 0);
+ rtx fnaddr = XEXP (DECL_RTL (fndecl), 0);
rtx sc_reg = force_reg (Pmode, static_chain);
emit_library_call (gen_rtx_SYMBOL_REF (SImode, "__trampoline_setup"),
aligning trampolines. */
#define TRAMPOLINE_ALIGNMENT (TARGET_FDPIC ? 64 : 32)
-/* A C statement to initialize the variable parts of a trampoline. ADDR is an
- RTX for the address of the trampoline; FNADDR is an RTX for the address of
- the nested function; STATIC_CHAIN is an RTX for the static chain value that
- should be passed to the function when it is called. */
-#define INITIALIZE_TRAMPOLINE(ADDR, FNADDR, STATIC_CHAIN) \
- frv_initialize_trampoline (ADDR, FNADDR, STATIC_CHAIN)
-
/* Define this macro if trampolines need a special subroutine to do their work.
The macro should expand to a series of `asm' statements which will be
compiled with GCC. They go in a library function named