This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[tuples][patch] Fix EH bug
- From: "Oleg Ryjkov" <olegr at google dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: "Diego Novillo" <dnovillo at google dot com>
- Date: Thu, 20 Mar 2008 19:12:30 -0700
- Subject: [tuples][patch] Fix EH bug
Hi all,
lower_try_finally was failing to set the resulting lowered sequence in
cases when the finally block can is removed.
Tested on i686-linux, about 180 testcases fixed.
Oleg
2008-03-20 Oleg Ryjkov <olegr@google.com>
* tree-eh.c (lower_try_finally): Correctly set the lowered sequence.
Index: tree-eh.c
===================================================================
--- tree-eh.c (revision 133397)
+++ tree-eh.c (working copy)
@@ -1546,7 +1546,10 @@ lower_try_finally (struct leh_state *sta
/* If the FINALLY block is not reachable, dike it out. */
if (ndests == 0)
+ {
+ gimple_seq_add_seq (&this_tf.top_p_seq, gimple_try_eval (tp));
gimple_try_set_cleanup (tp, NULL);
+ }
/* If the finally block doesn't fall through, then any destination
we might try to impose there isn't reached either. There may be
some minor amount of cleanup and redirection still needed. */
Index: ChangeLog.tuples
===================================================================
--- ChangeLog.tuples (revision 133404)
+++ ChangeLog.tuples (working copy)
@@ -1,3 +1,7 @@
+2008-03-20 Oleg Ryjkov <olegr@google.com>
+
+ * tree-eh.c (lower_try_finally): Correctly set the lowered sequence.
+
2008-03-20 Jakub Staszak <kuba@et.pl>
Oleg Ryjkov <olegr@google.com>