On Fri, Aug 31, 2012 at 10:58:51AM -0700, Steve Ellcey  wrote:
> Here is my patch to fix the bootstrap comparision failure (PR 54128) on
> MIPS.  The reason for the comparision failure was a difference in
> register usage and I tracked it down to build_insn_chain which checked
> all instructions for register usage in order to set the dead_or_set
> and live_relevant_regs bitmaps instead of checking only non-debug
> instructions.  Changing INSN_P to NONDEBUG_INSN_P in build_insn_chain
> allowed me to bootstrap and caused no regressions.
> 
> OK to checkin?

Given Alex' comments in the PR, the second hunk is definitely ok for trunk,
the first one can be applied too (but you can skip it too if you want, it
shouldn't make a difference).

> 2012-08-31  Steve Ellcey  <sell...@mips.com>
> 
>       PR bootstrap/54128
>       * ira.c (build_insn_chain): Check only NONDEBUG instructions for
>       register usage.
> 
> diff --git a/gcc/ira.c b/gcc/ira.c
> index 3825498..477c87b 100644
> --- a/gcc/ira.c
> +++ b/gcc/ira.c
> @@ -3341,7 +3341,7 @@ build_insn_chain (void)
>             c->insn = insn;
>             c->block = bb->index;
>  
> -           if (INSN_P (insn))
> +           if (NONDEBUG_INSN_P (insn))
>               for (def_rec = DF_INSN_UID_DEFS (uid); *def_rec; def_rec++)
>                 {
>                   df_ref def = *def_rec;
> @@ -3432,7 +3432,7 @@ build_insn_chain (void)
>             bitmap_and_compl_into (live_relevant_regs, elim_regset);
>             bitmap_copy (&c->live_throughout, live_relevant_regs);
>  
> -           if (INSN_P (insn))
> +           if (NONDEBUG_INSN_P (insn))
>               for (use_rec = DF_INSN_UID_USES (uid); *use_rec; use_rec++)
>                 {
>                   df_ref use = *use_rec;

        Jakub

Reply via email to