https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79389
--- Comment #12 from Jakub Jelinek <jakub at gcc dot gnu.org> --- At -O3 it is caused by the r238005 change as written earlier, that is really not a beneficial optimization in this case. -O3 -fno-split-paths should still see the benefit of the patch I've attached. So we need some patch from Richard too or a way to undo the damage afterwards (still in GIMPLE or on RTL).