https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110923
--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jan Hubicka <hubi...@gcc.gnu.org>: https://gcc.gnu.org/g:39204ae9ddbfca710880d7f5fda48234a1e85e4e commit r14-3133-g39204ae9ddbfca710880d7f5fda48234a1e85e4e Author: Jan Hubicka <j...@suse.cz> Date: Fri Aug 11 00:23:14 2023 +0200 Fix division by zero in loop splitting Profile update I added to tree-ssa-loop-split can divide by zero in situation that the conditional is predicted with 0 probability which is triggered by jump threading update in the testcase. gcc/ChangeLog: PR middle-end/110923 * tree-ssa-loop-split.cc (split_loop): Watch for division by zero. gcc/testsuite/ChangeLog: PR middle-end/110923 * gcc.dg/tree-ssa/pr110923.c: New test.