diff options
author | Steven Bosscher <steven@gcc.gnu.org> | 2007-04-01 18:26:00 +0000 |
---|---|---|
committer | Steven Bosscher <steven@gcc.gnu.org> | 2007-04-01 18:26:00 +0000 |
commit | 5b52976bb8586161e10f6544b69e6fa236aaa829 (patch) | |
tree | 25e1523fe427b1555d249aa5184ca9317aea6ae2 | |
parent | af33044f0598837e9dc2d584bb350ee2a5af156c (diff) | |
download | gcc-5b52976bb8586161e10f6544b69e6fa236aaa829.zip gcc-5b52976bb8586161e10f6544b69e6fa236aaa829.tar.gz gcc-5b52976bb8586161e10f6544b69e6fa236aaa829.tar.bz2 |
re PR rtl-optimization/31391 (undefined label with -O -g due to cfglayout)
PR rtl-optimization/31391
* cfgcleanup.c (try_optimize_cfg): If a removed label is turned
into a DELETED_LABEL note, and the label is in an empty basic
block, update BB_END as well as BB_HEAD.
From-SVN: r123406
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/cfgcleanup.c | 2 |
2 files changed, 9 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 81606be..2e2f90c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2007-04-01 Steven Bosscher <steven@gcc.gnu.org> + + PR rtl-optimization/31391 + * cfgcleanup.c (try_optimize_cfg): If a removed label is turned + into a DELETED_LABEL note, and the label is in an empty basic + block, update BB_END as well as BB_HEAD. + 2007-04-01 Richard Henderson <rth@redhat.com> PR tree-optimization/31169 diff --git a/gcc/cfgcleanup.c b/gcc/cfgcleanup.c index ee5c69b..c2595ea 100644 --- a/gcc/cfgcleanup.c +++ b/gcc/cfgcleanup.c @@ -2034,6 +2034,8 @@ try_optimize_cfg (int mode) reorder_insns_nobb (label, label, bb_note); BB_HEAD (b) = bb_note; + if (BB_END (b) == bb_note) + BB_END (b) = label; } if (dump_file) fprintf (dump_file, "Deleted label in block %i.\n", |