https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108992
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Why do you think this is a bug? I don't see anything wrong with the newer versions of gcc. Duplicating the basic blocks is done on purpose for speed reasons.