Commit 99819c63 by Jakub Jelinek Committed by Jakub Jelinek

re PR middle-end/34608 (ICE with "-ftest-coverage -fopenmp")

	PR middle-end/34608
	* omp-low.c (expand_omp_parallel): Purge dead EH edges in the
	child fn.

	* g++.dg/gomp/pr34608.C: New test.

From-SVN: r131264
parent caf38560
2008-01-03 Jakub Jelinek <jakub@redhat.com>
PR middle-end/34608
* omp-low.c (expand_omp_parallel): Purge dead EH edges in the
child fn.
2008-01-02 Richard Sandiford <rsandifo@nildram.co.uk> 2008-01-02 Richard Sandiford <rsandifo@nildram.co.uk>
* tree-sra.c (scalarize_init): Insert the generate_element_init * tree-sra.c (scalarize_init): Insert the generate_element_init
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
marshalling to implement data sharing and copying clauses. marshalling to implement data sharing and copying clauses.
Contributed by Diego Novillo <dnovillo@redhat.com> Contributed by Diego Novillo <dnovillo@redhat.com>
Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc. Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -2646,6 +2646,24 @@ expand_omp_parallel (struct omp_region *region) ...@@ -2646,6 +2646,24 @@ expand_omp_parallel (struct omp_region *region)
if (optimize) if (optimize)
optimize_omp_library_calls (); optimize_omp_library_calls ();
rebuild_cgraph_edges (); rebuild_cgraph_edges ();
/* Some EH regions might become dead, see PR34608. If
pass_cleanup_cfg isn't the first pass to happen with the
new child, these dead EH edges might cause problems.
Clean them up now. */
if (flag_exceptions)
{
basic_block bb;
tree save_current = current_function_decl;
bool changed = false;
current_function_decl = child_fn;
FOR_EACH_BB (bb)
changed |= tree_purge_dead_eh_edges (bb);
if (changed)
cleanup_tree_cfg ();
current_function_decl = save_current;
}
pop_cfun (); pop_cfun ();
} }
......
2008-01-03 Jakub Jelinek <jakub@redhat.com>
PR middle-end/34608
* g++.dg/gomp/pr34608.C: New test.
2008-01-02 Richard Guenther <rguenther@suse.de> 2008-01-02 Richard Guenther <rguenther@suse.de>
PR middle-end/34093 PR middle-end/34093
// PR middle-end/34608
// { dg-do compile }
// { dg-options "-ftest-coverage -fopenmp" }
struct A
{
~A () throw ();
};
void foo (A);
void
bar ()
{
#pragma omp parallel
foo (A ());
}
// { dg-final { cleanup-coverage-files } }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment