diff options
author | Roger Sayle <roger@eyesopen.com> | 2005-01-06 18:05:27 +0000 |
---|---|---|
committer | Roger Sayle <sayle@gcc.gnu.org> | 2005-01-06 18:05:27 +0000 |
commit | 4ab8006314c6e08c6e63e0743bf0a7e18c38792f (patch) | |
tree | 17c2e2babfaf3e6e9a7dc4233870ebcfdf9d99a1 | |
parent | 12d3e34bd585520cd1587ad9eb1cd7b3b6081a32 (diff) | |
download | gcc-4ab8006314c6e08c6e63e0743bf0a7e18c38792f.zip gcc-4ab8006314c6e08c6e63e0743bf0a7e18c38792f.tar.gz gcc-4ab8006314c6e08c6e63e0743bf0a7e18c38792f.tar.bz2 |
cfgrtl.c (rtl_delete_block): A basic block may be followed by more than one barrier...
* cfgrtl.c (rtl_delete_block): A basic block may be followed by
more than one barrier, in which case we should delete them all.
From-SVN: r92996
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/cfgrtl.c | 11 |
2 files changed, 12 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 669df34..730aa16 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2005-01-06 Roger Sayle <roger@eyesopen.com> + + * cfgrtl.c (rtl_delete_block): A basic block may be followed by + more than one barrier, in which case we should delete them all. + 2005-01-06 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de> * gcc.c (process_command): Change year in 'gcc --version' to 2005. diff --git a/gcc/cfgrtl.c b/gcc/cfgrtl.c index 90bd95f..fa0af4b 100644 --- a/gcc/cfgrtl.c +++ b/gcc/cfgrtl.c @@ -1,6 +1,6 @@ /* Control flow graph manipulation code for GNU compiler. Copyright (C) 1987, 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998, - 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. + 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. This file is part of GCC. @@ -379,10 +379,13 @@ rtl_delete_block (basic_block b) if (tablejump_p (end, NULL, &tmp)) end = tmp; - /* Include any barrier that may follow the basic block. */ + /* Include any barriers that may follow the basic block. */ tmp = next_nonnote_insn (end); - if (tmp && BARRIER_P (tmp)) - end = tmp; + while (tmp && BARRIER_P (tmp)) + { + end = tmp; + tmp = next_nonnote_insn (end); + } /* Selectively delete the entire chain. */ BB_HEAD (b) = NULL; |