This is the mail archive of the
mailing list for the GCC project.
Re: Avoiding REG+OFF memory accesses
- From: Iceman <iceman_dvd at yahoo dot com>
- To: Michael Meissner <meissner at linux dot vnet dot ibm dot com>, Ian Lance Taylor <iant at google dot com>
- Cc: gcc at gnu dot org
- Date: Fri, 8 May 2009 14:05:18 -0700 (PDT)
- Subject: Re: Avoiding REG+OFF memory accesses
- References: <firstname.lastname@example.org> <email@example.com> <20090508184743.GB18919@hungry-tiger.westford.ibm.com>
Ian suggestion worked perfectly, thanks. Can you tell me the macro/function name to look up
to work out the secondary reload you're mentioning?
----- Original Message ----
From: Michael Meissner <firstname.lastname@example.org>
To: Ian Lance Taylor <email@example.com>
Cc: Iceman <firstname.lastname@example.org>; email@example.com
Sent: Friday, May 8, 2009 11:47:43 AM
Subject: Re: Avoiding REG+OFF memory accesses
On Wed, May 06, 2009 at 05:01:33PM -0700, Ian Lance Taylor wrote:
> Iceman <firstname.lastname@example.org> writes:
> > Sorry for such trivial question, but is there any macro that can be used to avoig GCC to generate
> > REG+OFF memory accesses?
> > So basically to force GCC to break:
> > (mem (plus (reg const_int)))
> > into
> > (set regtmp (plus (reg const_int)))
> > (set (mem regtmp) reg)
> > This w/out writing custom RTL.
> Assuming this is a private port, this should happen more or less
> automatically if GO_IF_LEGITIMATE_ADDRESS rejects register plus offset
> If that is not what you are looking for, I think you need to provide
> some more context.
And you may also need to provide secondary reload support as well to convert
spill addresses into just REG addresses.
Michael Meissner, IBM
4 Technology Place Drive, MS 2203A, Westford, MA, 01886, USA