https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114792

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rguenth at gcc dot gnu.org

--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
The issue is that unloop_loops doesn't work when to unloop loops are nested. 
The unroller takes great care of working on a single loop level at a time,
cleaning up the CFG and fixing loops inbetween but we fail to ensure this here.

unlooping in CH is somewhat a wrong tool for the wrong task as it doesn't
adhere to constraints present.  There's the possibility this can be salvaged by
making unloop_loops more robust, in particular computing loop bodies (Which is
fragile) up-front.

But it would be much nicer if unlooping would simply add __builtin_unreachable
() as the first stmt into the latch and leave the rest to CFG cleanup.

Reply via email to