This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: sh64-elf (SH5) port
- From: Zack Weinberg <zack at codesourcery dot com>
- To: Alexandre Oliva <aoliva at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Sun, 3 Feb 2002 10:14:45 -0800
- Subject: Re: sh64-elf (SH5) port
- References: <orwuxux40b.fsf@free.redhat.lsd.ic.unicamp.br>
On Sun, Feb 03, 2002 at 08:18:28AM -0200, Alexandre Oliva wrote:
...
> The following change is necessary for SH5's TRAMPOLINE_ADJUST_ADDRESS
> to be able to reference add_optab. This was necessary because I have
> to set the lowest bit of the trampoline address when generating a
> trampoline in SHmedia mode (the lowest bit of a function address is
> used to indicate whether it's in SHcompact of SHmedia mode):
...
> +#define TRAMPOLINE_ADJUST_ADDRESS(TRAMP) do \
> +{ \
> + if (TARGET_SH5) \
> + (TRAMP) = expand_binop (Pmode, add_optab, (TRAMP), GEN_INT (1), \
> + gen_reg_rtx (Pmode), 0, OPTAB_LIB_WIDEN); \
> +} while (0)
> +
>
> I'd appreciate suggestions on other ways to overcome this problem.
You can use expand_simple_binop here: just change add_optab to PLUS.
zw