https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59922
--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Eric Gallager from comment #3) > Confirmed. Happens with optimization levels -O0 and -Os, but not -O1, -O2, > -O3, -Og, or -Ofast. That is because of the way finally is expanded. With -O0 and -Os the final block is not duplicated