aboutsummaryrefslogtreecommitdiff
path: root/gcc/cfgrtl.c
diff options
context:
space:
mode:
authorTom de Vries <tom@codesourcery.com>2013-02-25 11:50:25 +0000
committerTom de Vries <vries@gcc.gnu.org>2013-02-25 11:50:25 +0000
commit5e5df392f8264116f1b75ead4ad6d1e6b99945a6 (patch)
treeb5cc77bdb6a9aa017f4449f30d95a3ef88801dea /gcc/cfgrtl.c
parent3fdb53c1ea5e52f1db57f20ed22dbe0081da7017 (diff)
downloadgcc-5e5df392f8264116f1b75ead4ad6d1e6b99945a6.zip
gcc-5e5df392f8264116f1b75ead4ad6d1e6b99945a6.tar.gz
gcc-5e5df392f8264116f1b75ead4ad6d1e6b99945a6.tar.bz2
re PR rtl-optimization/56131 (gcc.dg/pr56035.c ICEs gcc on sparc-linux)
2013-02-25 Tom de Vries <tom@codesourcery.com> PR rtl-optimization/56131 * insn-notes.def (INSN_NOTE_BASIC_BLOCK): Update comment. * cfgrtl.c (delete_insn): Don't reorder NOTE_INSN_DELETED_LABEL and NOTE_INSN_BASIC_BLOCK if BLOCK_FOR_INSN == NULL. From-SVN: r196255
Diffstat (limited to 'gcc/cfgrtl.c')
-rw-r--r--gcc/cfgrtl.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/gcc/cfgrtl.c b/gcc/cfgrtl.c
index c6ed44f..ec1ba9a 100644
--- a/gcc/cfgrtl.c
+++ b/gcc/cfgrtl.c
@@ -135,7 +135,7 @@ delete_insn (rtx insn)
if (! can_delete_label_p (insn))
{
const char *name = LABEL_NAME (insn);
- basic_block bb, label_bb = BLOCK_FOR_INSN (insn);
+ basic_block bb = BLOCK_FOR_INSN (insn);
rtx bb_note = NEXT_INSN (insn);
really_delete = false;
@@ -144,15 +144,13 @@ delete_insn (rtx insn)
NOTE_DELETED_LABEL_NAME (insn) = name;
/* If the note following the label starts a basic block, and the
- label is a member of the same basic block, interchange the two.
- If the label is not marked with a bb, assume it's the same bb. */
+ label is a member of the same basic block, interchange the two. */
if (bb_note != NULL_RTX
&& NOTE_INSN_BASIC_BLOCK_P (bb_note)
- && (label_bb == NOTE_BASIC_BLOCK (bb_note)
- || label_bb == NULL))
+ && bb != NULL
+ && bb == BLOCK_FOR_INSN (bb_note))
{
reorder_insns_nobb (insn, insn, bb_note);
- bb = NOTE_BASIC_BLOCK (bb_note);
BB_HEAD (bb) = bb_note;
if (BB_END (bb) == bb_note)
BB_END (bb) = insn;