This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: About Regmove !!
- From: tm <tm at mail dot kloo dot net>
- To: law at redhat dot com
- Cc: Michael Matz <matz at suse dot de>, joern dot rennecke at superh dot com,gcc at gcc dot gnu dot org
- Date: Tue, 12 Nov 2002 11:43:19 -0800 (PST)
- Subject: Re: About Regmove !!
On Tue, 12 Nov 2002, Jeff Law wrote:
> In message <Pine.LNX.4.21.0211121052080.12360-100000@mail.kloo.net>, tm writes:
> >On Tue, 12 Nov 2002, Michael Matz wrote:
> >>
> >> > Does new-regalloc do address inheritance optimization?
> >>
> >> No (t yet?).
> >>
> >> > If not, can we retain the portion of regmove which implements this
> >> > optimization?
> >>
> >> Of course.
> >
> >Okay. Please keep this in mind.
> Note there are other ways to do this kind of optimization. For example,
> look at how folks have integrated strength reduction and gcse. Better
> yet, you get these optimizations on a global basis rather than local or
> extended basic block.
>
> jeff
Yep.
The current implementation has one huge problem: it doesn't work well with
GCSE. What happens is that LEGITIMIZE_ADDRESS breaks up large offsets into
address arithmetic, then GCSE comes along and hoists part of the address
arithmetic into another basic block where regmove can't optimize it.
It would be nice if we could run a regmove-like pass before GCSE, then use
GCSE as a back-end to link together the address inheritance chain across
basic blocks.
Are there any obvious conceptual deficiencies with this approach?
Toshi