https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101145
--- Comment #8 from Jiu Fu Guo <guojiufu at gcc dot gnu.org> --- Reference the code of adjust_cond_for_loop_until_wrap, add code for non-const cases. Code was added in adjust_cond_for_loop_until_wrap at beginning, to set may_be_zero and no_overflow, the code was moved to number_of_iterations_lt at last. The patch was submitted as: https://gcc.gnu.org/pipermail/gcc-patches/2021-July/574110.html