This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] combine: Delete EQ* notes when pseudo mode changes (PR60818)
- From: Segher Boessenkool <segher at kernel dot crashing dot org>
- To: Eric Botcazou <ebotcazou at adacore dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Fri, 19 Feb 2016 04:37:31 -0600
- Subject: Re: [PATCH] combine: Delete EQ* notes when pseudo mode changes (PR60818)
- Authentication-results: sourceware.org; auth=none
- References: <71ce2561d2dd574e38b062a094f4ce41cac21a84 dot 1455873752 dot git dot segher at kernel dot crashing dot org> <1866788 dot QrLM6i8spP at polaris>
On Fri, Feb 19, 2016 at 11:27:48AM +0100, Eric Botcazou wrote:
> > 2016-02-19 Segher Boessenkool <segher@kernel.crashing.org>
> >
> > PR 60818/rtl-optimization
> > * combine.c (combine_remove_reg_equal_equiv_notes_for_regno):
> > New function.
> > (try_combine): Call it when SELECT_CC_MODE makes us change the
> > mode of a pseudo.
>
> This looks like a big hammer to me though.
Do you have something smaller in mind that still works? I'm all ears.
> > +/* Remove all REG_EQUAL and REG_EQUIV notes referring to REGNO. This is
> > + like rtlanal's remove_reg_equal_equiv_notes_for_regno but with some big
> > + differences, because combine does not keep the DF info up-to-date.
> > + We do however never add or move these notes during combine, so we can
> > + still use the DF info as it was at the start of combine to find all
> > + such notes. */
>
> The comment is wrong, or at least confusing, since distribute_notes does deal
> with REG_EQUAL and REG_EQUIV notes.
But it never adds or moves these notes. It even says so :-)
Segher