This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Avoid extending reg lifetime when cprop_hardreg propagates into DEBUG_INSNs (PR debug/43161)
- From: Steven Bosscher <stevenb dot gcc at gmail dot com>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org, Alexandre Oliva <aoliva at redhat dot com>
- Date: Wed, 24 Feb 2010 23:19:32 +0100
- Subject: Re: [PATCH] Avoid extending reg lifetime when cprop_hardreg propagates into DEBUG_INSNs (PR debug/43161)
- References: <20100224195742.GJ2817@tyan-ft48-01.lab.bos.redhat.com>
On Wed, Feb 24, 2010 at 8:57 PM, Jakub Jelinek <jakub@redhat.com> wrote:
> @@ -446,6 +480,23 @@ replace_oldest_value_reg (rtx *loc, enum
> ? rtx new_rtx = find_oldest_value_reg (cl, *loc, vd);
> ? if (new_rtx)
> ? ? {
> + ? ? ?if (DEBUG_INSN_P (insn))
> + ? ? ? {
> + ? ? ? ? struct queued_debug_insn_change *change;
> +
> + ? ? ? ? if (dump_file)
> + ? ? ? ? ? fprintf (dump_file, "debug_insn %u: queued replacing reg %u with %u\n",
> + ? ? ? ? ? ? ? ? ? ?INSN_UID (insn), REGNO (*loc), REGNO (new_rtx));
> +
> + ? ? ? ? change = XNEW (struct queued_debug_insn_change);
Maybe use an alloc pool instead? Or an obstack that you clear per EBB?
Ciao!
Steven