On Wed, 2009-08-26 at 23:30 +0200, Richard Guenther wrote:
> On Wed, Aug 26, 2009 at 10:47 PM, Peter Bergner<[email protected]> wrote:
> > Looking at update_equiv_regs(), if I disable the replacement for regs
> > that are local to one basic block (patch below) like it existed before
> > John Wehle's patch way back in Oct 2000:
> >
> > http://gcc.gnu.org/ml/gcc-patches/2000-09/msg00782.html
> >
> > then we get the ordering we want. Does anyone know why John removed
> > that part of the test in his patch? Thoughts anyone?
>
> Hmm. I suppose if you conditionalize it on flag_schedule_insns it might be
> an overall win. Care to SPEC test that change?
I assume you mean like the change below? Yeah, I can SPEC test that.
Peter
Index: ira.c
===================================================================
--- ira.c (revision 151111)
+++ ira.c (working copy)
@@ -2510,6 +2510,8 @@ update_equiv_regs (void)
calls. */
if (REG_N_REFS (regno) == 2
+ && (!flag_schedule_insns
+ || REG_BASIC_BLOCK (regno) < NUM_FIXED_BLOCKS)
&& (rtx_equal_p (x, src)
|| ! equiv_init_varies_p (src))
&& NONJUMP_INSN_P (insn)