This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [rfc] multi-word subreg lowering pass
- From: Björn Haase <bjoern dot m dot haase at web dot de>
- To: Rask Ingemann Lambertsen <rask at sygehus dot dk>
- Cc: Richard Henderson <rth at redhat dot com>, gcc-patches at gcc dot gnu dot org
- Date: Mon, 3 Jul 2006 23:01:33 +0200
- Subject: Re: [rfc] multi-word subreg lowering pass
- References: <200505062218.15370.bjoern.m.haase@web.de> <20050507033326.GC23300@redhat.com> <20060702183612.GB2611@sygehus.dk>
Rask Ingemann Lambertsen wrote on Sonntag, 2. Juli 2006 20:36 :
> On Fri, May 06, 2005 at 08:33:26PM -0700, Richard Henderson wrote:
> > If the target leaves logical arithmetic to the middle end, this
> > means that the posted example,
> >
> > long long foo(int x, long long y)
> > {
> > return x & y;
> > }
> >
> > will decompose to
> >
> > (set (reg:SI 100) (reg:SI x))
> > (set (reg:SI 101) (const_int 0))
> > (set (reg:SI 102) (and:SI (reg:SI 100) (reg:SI ylow)))
> > (set (reg:SI 103) (and:SI (reg:SI 101) (reg:SI yhigh)))
> > (set (reg:SI eax) (reg:SI 102))
> > (set (reg:SI edx) (reg:SI 103))
> >
> > which after cse and combine will be just perfect.
>
> How do you prevent combine from reinserting the subregs into the insns?
> Given the function
>
> ...
>
> Combine combines insn 25 and insn 72 into insn 72, undoing the efforts of
> the subreg lowering pass.
Maybe this is again another hint that one should delay the lowering until
after combine.?
Bjoern.