diff options
author | Bernd Schmidt <bernds@codesourcery.com> | 2010-09-24 11:29:59 +0000 |
---|---|---|
committer | Bernd Schmidt <bernds@gcc.gnu.org> | 2010-09-24 11:29:59 +0000 |
commit | 662592e1bac8b26f51e4b3c3e694b7d909487d3b (patch) | |
tree | ab51341f3caa8c5b0917e78b80af5fd993c1f920 /gcc | |
parent | e2686b2d7618aefeeb4b62c4d0731ca24c17c1e6 (diff) | |
download | gcc-662592e1bac8b26f51e4b3c3e694b7d909487d3b.zip gcc-662592e1bac8b26f51e4b3c3e694b7d909487d3b.tar.gz gcc-662592e1bac8b26f51e4b3c3e694b7d909487d3b.tar.bz2 |
cfgcleanup.c (flow_find_head_matching_sequence): Terminate when reaching the end of a block if it occurs at a DEBUG_INSN.
* cfgcleanup.c (flow_find_head_matching_sequence): Terminate when
reaching the end of a block if it occurs at a DEBUG_INSN.
From-SVN: r164589
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/cfgcleanup.c | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 619461d..7d85ec5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2010-09-24 Bernd Schmidt <bernds@codesourcery.com> + + * cfgcleanup.c (flow_find_head_matching_sequence): Terminate when + reaching the end of a block if it occurs at a DEBUG_INSN. + 2010-09-09 Tristan Gingold <gingold@adacore.com> PR target/44242 diff --git a/gcc/cfgcleanup.c b/gcc/cfgcleanup.c index 6b128eb..9f3e68e 100644 --- a/gcc/cfgcleanup.c +++ b/gcc/cfgcleanup.c @@ -1184,7 +1184,6 @@ flow_find_head_matching_sequence (basic_block bb1, basic_block bb2, rtx *f1, while (true) { - /* Ignore notes. */ while (!NONDEBUG_INSN_P (i1) && i1 != BB_END (bb1)) i1 = NEXT_INSN (i1); @@ -1192,6 +1191,10 @@ flow_find_head_matching_sequence (basic_block bb1, basic_block bb2, rtx *f1, while (!NONDEBUG_INSN_P (i2) && i2 != BB_END (bb2)) i2 = NEXT_INSN (i2); + if ((i1 == BB_END (bb1) && !NONDEBUG_INSN_P (i1)) + || (i2 == BB_END (bb2) && !NONDEBUG_INSN_P (i2))) + break; + if (NOTE_P (i1) || NOTE_P (i2) || JUMP_P (i1) || JUMP_P (i2)) break; |