This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix PR middle-end/28690, indexed load/store performance + reload bug

On Tue, 2006-12-05 at 14:04 +0100, Ulrich Weigand wrote:
> Peter Bergner wrote:
> > +  /* Guard against a PARALLEL with a REG_UNUSED note.  */
> > +  if (GET_CODE (PATTERN (insn)) != PARALLEL)
> > +    old_set = single_set (insn);
> > +  else
> > +    old_set = 0;
> > +
> >    if (old_set != 0 && REG_P (SET_DEST (old_set))
> >        && REGNO (SET_DEST (old_set)) < FIRST_PSEUDO_REGISTER)
> >      {
> I'm not sure about this change.  I'm afraid on platforms where
> add instructions are usually a PARALLEL (with a clobber of the
> condition code register), the change may cause eliminate_regs_in_insn
> to miss instructions that *set* an eliminable register (what the
> loop immediately following the above lines tries to find).
> I'd expect this to cause problems e.g. on s390 ..

Then how about a scheme where we continue to call single_set() as
we do now.  However, if single_set() returns non null and the insn
is a PARALLEL, then we recursively call eliminate_regs_in_insn() for
the portion(s) of the PARALLEL not returned by single_set()?  That would
allow this portion of the code to behave as before, while allowing
the unused portion of the PARALLEL to have it's regs eliminated.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]