http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60221

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |rguenth at gcc dot 
gnu.org

--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
Note that we do run ehcleanup2 at -O0, but we have EH unsplitting and empty
EH removal disabled if not optimizing.

So we could simply do

Index: tree-eh.c
===================================================================
--- tree-eh.c   (revision 207837)
+++ tree-eh.c   (working copy)
@@ -4557,11 +4557,12 @@ execute_cleanup_eh_1 (void)
   remove_unreachable_handlers ();

   /* Watch out for the region tree vanishing due to all unreachable.  */
-  if (cfun->eh->region_tree && optimize)
+  if (cfun->eh->region_tree)
     {
       bool changed = false;

-      changed |= unsplit_all_eh ();
+      if (optimize)
+       changed |= unsplit_all_eh ();
       changed |= cleanup_all_empty_eh ();

       if (changed)

Testing that.

Reply via email to