re PR tree-optimization/33735 (verify_stmts failed: missing PHI def)

gcc/ChangeLog:
PR tree-optimization/33735
PR tree-optimization/33572
* tree-inline.c (update_ssa_across_abnormal_edges): Revert
2007-10-09's change.
* except.c (duplicate_eh_regions): Don't look for prev_try
beyond ERT_ALLOWED_EXCEPTIONS with an empty list.
gcc/testsuite/ChangeLog:
PR tree-optimization/33735
* g++.dg/torture/pr33735.C: New.

From-SVN: r129356
This commit is contained in:
Alexandre Oliva 2007-10-15 17:07:20 +00:00 committed by Alexandre Oliva
parent aa79283408
commit 1432b19f40
5 changed files with 39 additions and 3 deletions

View file

@ -1,3 +1,12 @@
2007-10-15 Alexandre Oliva <aoliva@redhat.com>
PR tree-optimization/33735
PR tree-optimization/33572
* tree-inline.c (update_ssa_across_abnormal_edges): Revert
2007-10-09's change.
* except.c (duplicate_eh_regions): Don't look for prev_try
beyond ERT_ALLOWED_EXCEPTIONS with an empty list.
2007-10-15 Alexandre Oliva <aoliva@redhat.com>
PR middle-end/33706

View file

@ -1005,7 +1005,9 @@ duplicate_eh_regions (struct function *ifun, duplicate_eh_regions_map map,
for (prev_try = VEC_index (eh_region, cfun->eh->region_array, outer_region);
prev_try && prev_try->type != ERT_TRY;
prev_try = prev_try->outer)
if (prev_try->type == ERT_MUST_NOT_THROW)
if (prev_try->type == ERT_MUST_NOT_THROW
|| (prev_try->type == ERT_ALLOWED_EXCEPTIONS
&& !prev_try->u.allowed.type_list))
{
prev_try = NULL;
break;

View file

@ -1,3 +1,8 @@
2007-10-15 Alexandre Oliva <aoliva@redhat.com>
PR tree-optimization/33735
* g++.dg/torture/pr33735.C: New.
2007-10-15 Alexandre Oliva <aoliva@redhat.com>
PR middle-end/33706

View file

@ -0,0 +1,21 @@
// { dg-do compile }
#include <string>
typedef struct _ts { } PyThreadState;
PyThreadState * Py_NewInterpreter(void);
void Py_EndInterpreter(PyThreadState *);
class ApplicationError {
public:
ApplicationError(std::string errormsg) : errormsg(errormsg) { }
std::string errormsg;
};
void run()
{
PyThreadState *py_state=__null;
try {
if (!(py_state=Py_NewInterpreter()))
throw ApplicationError("error");
}
catch(ApplicationError e) {
Py_EndInterpreter(py_state);
}
}

View file

@ -1064,8 +1064,7 @@ update_ssa_across_abnormal_edges (basic_block bb, basic_block ret_bb,
}
re = find_edge (ret_bb, e->dest);
if (!re)
continue;
gcc_assert (re);
gcc_assert ((re->flags & (EDGE_EH | EDGE_ABNORMAL))
== (e->flags & (EDGE_EH | EDGE_ABNORMAL)));