[Bug rtl-optimization/30773] [4.3 Regression] Spec cpu2k6/h264ref and sphinx3 miscompare regression
steven at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Fri Feb 16 05:26:00 GMT 2007
------- Comment #6 from steven at gcc dot gnu dot org 2007-02-16 05:26 -------
What Ian said is probably right, and the patch below should fix it. I haven't
tried it yet, though...
Index: local-alloc.c
===================================================================
--- local-alloc.c (revision 122011)
+++ local-alloc.c (working copy)
@@ -1064,12 +1064,16 @@ update_equiv_regs (void)
if (validate_equiv_mem (init_insn, src, dest)
&& ! memref_used_between_p (dest, init_insn, insn))
{
- set_unique_reg_note (init_insn, REG_EQUIV, copy_rtx (dest));
-
- /* This insn makes the equivalence, not the one initializing
- the register. */
- reg_equiv_init[regno]
- = gen_rtx_INSN_LIST (VOIDmode, insn, NULL_RTX);
+ /* Try to set a REG_EQUIV note. This may fail if init_insn
+ has multiple sets. */
+ if (set_unique_reg_note (init_insn, REG_EQUIV,
+ copy_rtx (dest)))
+ {
+ /* This insn makes the equivalence, not the one initializing
+ the register. */
+ reg_equiv_init[regno]
+ = gen_rtx_INSN_LIST (VOIDmode, insn, NULL_RTX);
+ }
}
}
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30773
More information about the Gcc-bugs
mailing list