This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: live insns deleted by delete_trivially_dead_insns()
- From: Ian Lance Taylor <iant at google dot com>
- To: Rask Ingemann Lambertsen <rask at sygehus dot dk>
- Cc: gcc at gcc dot gnu dot org
- Date: 08 May 2007 00:34:47 -0700
- Subject: Re: live insns deleted by delete_trivially_dead_insns()
- References: <20070507133916.GA3633@sygehus.dk>
Rask Ingemann Lambertsen <rask@sygehus.dk> writes:
> I'm seeing miscompilation of newlib's memcmp() for my 16-bit ix86 port. The
> REG_RETVAL and REG_LIBCALL notes seem to play an important part in the
> failure. From the first subreg dump:
Try this:
Index: gcc/lower-subreg.c
===================================================================
--- gcc/lower-subreg.c (revision 124389)
+++ gcc/lower-subreg.c (working copy)
@@ -610,7 +610,7 @@ resolve_reg_notes (rtx insn)
rtx *pnote, note;
note = find_reg_equal_equiv_note (insn);
- if (note)
+ if (note || find_reg_note (insn, REG_RETVAL, NULL) != NULL_RTX)
{
if (for_each_rtx (&XEXP (note, 0), resolve_subreg_use, NULL))
{