This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: [m68k]: convert mode 5 addressing w/zero offset into mode2
- From: Ian Lance Taylor <ian at wasabisystems dot com>
- To: Peter Barada <peter at the-baradas dot com>
- Cc: binutils at sources dot redhat dot com
- Date: 27 May 2004 11:00:28 -0400
- Subject: Re: [m68k]: convert mode 5 addressing w/zero offset into mode2
- References: <20040527145619.81C22990F3@baradas.org>
Peter Barada <peter@the-baradas.com> writes:
> This following patch converts:
>
> <op> 0(%Ay),%Rx
> <op> %Ry,0(%Ax)
> <op> 0(%Ay),0(%Ax)
>
> into:
>
> <op> (%Ay),%Rx
> <op> %Ry,(%Ax)
> <op> (%Ay),(%Ax)
>
> To reduce the size of the instruction by the word used to hold the
> offset.
This kind of patch makes me nervous. Sometimes people write assembler
code with the full intention of generating a specific addressing mode,
even if it is apparently less efficient. I'm not sure it is
appropriate for the assembler to second-guess the programmer in a case
like this.
Ian