diff options
author | Richard Henderson <rth@redhat.com> | 2011-07-23 12:44:19 -0700 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2011-07-23 12:44:19 -0700 |
commit | 0be7e7a6dbb4cdf48e76bf9b38f42b95ebf4d752 (patch) | |
tree | 389d88dc095866e7b7f73e8f1553aa55bd3617a1 /gcc/cfgrtl.c | |
parent | e01705517ac38e207e8f52610a46ad0c4aca61e0 (diff) | |
download | gcc-0be7e7a6dbb4cdf48e76bf9b38f42b95ebf4d752.zip gcc-0be7e7a6dbb4cdf48e76bf9b38f42b95ebf4d752.tar.gz gcc-0be7e7a6dbb4cdf48e76bf9b38f42b95ebf4d752.tar.bz2 |
bb-reorder: Split EH edges crossing partitions.
From-SVN: r176696
Diffstat (limited to 'gcc/cfgrtl.c')
-rw-r--r-- | gcc/cfgrtl.c | 32 |
1 files changed, 26 insertions, 6 deletions
diff --git a/gcc/cfgrtl.c b/gcc/cfgrtl.c index b8843cae..076ff03 100644 --- a/gcc/cfgrtl.c +++ b/gcc/cfgrtl.c @@ -1820,18 +1820,38 @@ rtl_verify_flow_info_1 (void) } FOR_EACH_EDGE (e, ei, bb->succs) { + bool is_crossing; + if (e->flags & EDGE_FALLTHRU) + n_fallthru++, fallthru = e; + + is_crossing = (BB_PARTITION (e->src) != BB_PARTITION (e->dest) + && e->src != ENTRY_BLOCK_PTR + && e->dest != EXIT_BLOCK_PTR); + if (e->flags & EDGE_CROSSING) { - n_fallthru++, fallthru = e; - if ((e->flags & EDGE_CROSSING) - || (BB_PARTITION (e->src) != BB_PARTITION (e->dest) - && e->src != ENTRY_BLOCK_PTR - && e->dest != EXIT_BLOCK_PTR)) - { + if (!is_crossing) + { + error ("EDGE_CROSSING incorrectly set across same section"); + err = 1; + } + if (e->flags & EDGE_FALLTHRU) + { error ("fallthru edge crosses section boundary (bb %i)", e->src->index); err = 1; } + if (e->flags & EDGE_EH) + { + error ("EH edge crosses section boundary (bb %i)", + e->src->index); + err = 1; + } + } + else if (is_crossing) + { + error ("EDGE_CROSSING missing across section boundary"); + err = 1; } if ((e->flags & ~(EDGE_DFS_BACK |