The following code snippet causes an ICE when compiled with "-fopenmp":
============================== struct A { ~A() {} }; struct B { A a; B(); }; void foo() { #pragma omp parallel { B b[1]; new int; } } ============================== bug.cc: In function 'void foo()': bug.cc:12: internal compiler error: in add_stmt_to_eh_region_fn, at tree-eh.c:100 Please submit a full bug report, [etc.] This is probably the bug mentioned in comment #16 from PR26084. -- Summary: ICE with OpenMP in add_stmt_to_eh_region_fn, at tree- eh.c:100 Product: gcc Version: 4.2.0 Status: UNCONFIRMED Keywords: ice-on-valid-code, monitored, openmp Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: reichelt at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26823