summaryrefslogtreecommitdiff
path: root/gcc/dce.c
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2011-06-09 07:46:28 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2011-06-09 07:46:28 +0000
commit5af2c7fc3566ffcba936afd7b6aacf25fc4b8276 (patch)
tree04c78a3f0d60ea8375218ae474e406d2d7bf67f4 /gcc/dce.c
parentf9cccfac295bed8da7e640f24a625509c9cce5da (diff)
downloadgcc-5af2c7fc3566ffcba936afd7b6aacf25fc4b8276.tar.gz
PR middle-end/49308
* dce.c (reset_unmarked_insns_debug_uses): Avoid shadowing insn variable. After resetting and rescanning insn continue with previous statement. * gfortran.dg/pr49308.f90: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@174839 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/dce.c')
-rw-r--r--gcc/dce.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/dce.c b/gcc/dce.c
index 93464fedeed..997432501d3 100644
--- a/gcc/dce.c
+++ b/gcc/dce.c
@@ -514,11 +514,11 @@ reset_unmarked_insns_debug_uses (void)
struct df_link *defs;
for (defs = DF_REF_CHAIN (use); defs; defs = defs->next)
{
- rtx insn;
+ rtx ref_insn;
if (DF_REF_IS_ARTIFICIAL (defs->ref))
continue;
- insn = DF_REF_INSN (defs->ref);
- if (!marked_insn_p (insn))
+ ref_insn = DF_REF_INSN (defs->ref);
+ if (!marked_insn_p (ref_insn))
break;
}
if (!defs)
@@ -527,6 +527,7 @@ reset_unmarked_insns_debug_uses (void)
each of the DEFs? */
INSN_VAR_LOCATION_LOC (insn) = gen_rtx_UNKNOWN_VAR_LOC ();
df_insn_rescan_debug_internal (insn);
+ break;
}
}
}