diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2011-09-25 14:55:12 +0000 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2011-09-25 14:55:12 +0000 |
commit | 1ee0d6604012f8bf441431e191ea8484ecde1b00 (patch) | |
tree | d97d634cdfdfd430b5c57a9004ad433969b2d30b /gcc/tree-eh.c | |
parent | 8e19f5a1b3c48e05595cba58223fcb2ae1504599 (diff) | |
download | gcc-1ee0d6604012f8bf441431e191ea8484ecde1b00.zip gcc-1ee0d6604012f8bf441431e191ea8484ecde1b00.tar.gz gcc-1ee0d6604012f8bf441431e191ea8484ecde1b00.tar.bz2 |
tree-eh.c (cleanup_empty_eh): Allow a call to __builtin_stack_restore if there is no outgoing edge.
* tree-eh.c (cleanup_empty_eh): Allow a call to __builtin_stack_restore
if there is no outgoing edge.
* tree-scalar-evolution.c (simple_iv): Accept all kinds of pointer and
integral types.
From-SVN: r179165
Diffstat (limited to 'gcc/tree-eh.c')
-rw-r--r-- | gcc/tree-eh.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gcc/tree-eh.c b/gcc/tree-eh.c index f10d72d..3a58267 100644 --- a/gcc/tree-eh.c +++ b/gcc/tree-eh.c @@ -3863,8 +3863,15 @@ cleanup_empty_eh (eh_landing_pad lp) return cleanup_empty_eh_unsplit (bb, e_out, lp); } - /* The block should consist only of a single RESX statement. */ + /* The block should consist only of a single RESX statement, modulo a + preceding call to __builtin_stack_restore if there is no outgoing + edge, since the call can be eliminated in this case. */ resx = gsi_stmt (gsi); + if (!e_out && gimple_call_builtin_p (resx, BUILT_IN_STACK_RESTORE)) + { + gsi_next (&gsi); + resx = gsi_stmt (gsi); + } if (!is_gimple_resx (resx)) return false; gcc_assert (gsi_one_before_end_p (gsi)); |