Patchwork do not copy DEBUG_EXPRs in copy_insn

login
register
mail settings
Submitter Alexandre Oliva
Date Sept. 16, 2011, 7:04 a.m.
Message ID <orvcst9dd5.fsf@livre.localdomain>
Download mbox | patch
Permalink /patch/114893/
State New
Headers show

Comments

Alexandre Oliva - Sept. 16, 2011, 7:04 a.m.
copy_rtx avoids duplicating DEBUG_EXPRs, so that they map one-to-one to
DEBUG_EXPR_DECLs, but copy_insn lacks these smarts.  This was exposed by
a patch I'm working on, that uses RTL flags in DEBUG_EXPRs to speed up
expansion of var location notes within var-tracking.

Regstrapped on i686-pc-linux-gnu and x86_64-linux-gnu.  Ok to install?
Jakub Jelinek - Sept. 16, 2011, 8:18 a.m.
On Fri, Sep 16, 2011 at 04:04:54AM -0300, Alexandre Oliva wrote:
> from  Alexandre Oliva  <aoliva@redhat.com>
> 
> 	* emit-rtl.c (copy_insn_1): Do not copy DEBUG_EXPRs.

This is ok.

	Jakub

Patch

for  gcc/ChangeLog
from  Alexandre Oliva  <aoliva@redhat.com>

	* emit-rtl.c (copy_insn_1): Do not copy DEBUG_EXPRs.

Index: gcc/emit-rtl.c
===================================================================
--- gcc/emit-rtl.c.orig	2011-09-15 03:51:41.982777588 -0300
+++ gcc/emit-rtl.c	2011-09-15 03:51:50.767633680 -0300
@@ -5269,6 +5269,7 @@  copy_insn_1 (rtx orig)
   switch (code)
     {
     case REG:
+    case DEBUG_EXPR:
     case CONST_INT:
     case CONST_DOUBLE:
     case CONST_FIXED: