https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115810 --- Comment #10 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Can you provide the exact version of gcc you are using? The trunk works correctly.