This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: loop.c bugfix
- To: Alan Lehotsky <lehotsky at tiac dot net>
- Subject: Re: loop.c bugfix
- From: Bernd Schmidt <bernds at redhat dot co dot uk>
- Date: Mon, 23 Oct 2000 12:48:15 +0100 (BST)
- cc: Richard Kenner <kenner at vlsi1 dot ultra dot nyu dot edu>, gcc-patches at gcc dot gnu dot org, gcc at gcc dot gnu dot org
On Mon, 23 Oct 2000, Alan Lehotsky wrote:
> d = *(a+j);
>
> has to generate something like
>
> i4 = a; 'i4' is a base register...
> m4 = j; 'm4' is an index register....
>
> d = dm(m4,i4);
>
> because the chip doesn't treat address arithmetic as
> commutative! If you loaded the values a and j into the
> opposite register you'd access the wrong memory.
Then maybe what you really want is a different rtx code than PLUS?
Bernd