summaryrefslogtreecommitdiff
path: root/gcc/dse.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/dse.c')
-rw-r--r--gcc/dse.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/dse.c b/gcc/dse.c
index 2338d3240ba..3e6b57d6ca1 100644
--- a/gcc/dse.c
+++ b/gcc/dse.c
@@ -2387,6 +2387,11 @@ scan_insn (bb_info_t bb_info, rtx insn)
insn_info->insn = insn;
bb_info->last_insn = insn_info;
+ if (DEBUG_INSN_P (insn))
+ {
+ insn_info->cannot_delete = true;
+ return;
+ }
/* Cselib clears the table for this case, so we have to essentially
do the same. */