https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107114
--- Comment #1 from Andrew Macleod <amacleod at redhat dot com> --- Looks like something in the change is causing the loop analysis to not be able to count the iterations. > Analyzing # of iterations of loop 1 > exit condition [1, + , 1] != 0 > bounds on difference of bases: -1 ... -1 > result: > # of iterations 65535, bounded by 65535 109,110d68 < Loops range found for a_lsm.14_26: [irange] short int [1, 9] NONZERO 0xf and calculated range :[irange] short int VARYING < Global Exported: a_lsm.14_26 = [irange] short int [1, 9] NONZERO 0xf 112,114c70,72 < Loops range found for c_lsm.16_29: [irange] int [1, 2115902953] NONZERO 0x7fffffff and calculated range :[irange] int [-1618507910, +INF] < Global Exported: c_lsm.16_29 = [irange] int [1, 2115902953] NONZERO 0x7fffffff < Folding PHI node: a_lsm.14_26 = PHI <1(2), _11(12)> before this change, loop analysis decided the range of _26 as a_lsm.14_26: [irange] short int [1, 9] NONZERO 0xf a afterwards, it doesn't even seem to see the loop. IN fact, before LCSSA creates a whole bunch of new blocks too. < ;; Created LCSSA PHI: a_lsm.14_15 = PHI <a_lsm.14_26(8)> < ;; Created LCSSA PHI: a_lsm_flag.15_16 = PHI <a_lsm_flag.15_28(8)> < ;; Created LCSSA PHI: d_47 = PHI <d_13(7)> < < Updating SSA: < Registering new PHI nodes in block #13 < Updating SSA information for statement if (a_lsm.14_26 != 0) < Registering new PHI nodes in block #6 < Registering new PHI nodes in block #12 < Updating SSA information for statement a.9_9 = (unsigned short) a_lsm.14_26; < Registering new PHI nodes in block #16 < Registering new PHI nodes in block #7 < Registering new PHI nodes in block #8 < Updating SSA information for statement if (d_13 != 0B) < Registering new PHI nodes in block #9 < Updating SSA information for statement if (a_lsm_flag.15_28 != 0) < Registering new PHI nodes in block #10 < Updating SSA information for statement a = a_lsm.14_26; < Registering new PHI nodes in block #11 < Registering new PHI nodes in block #19 < Registering new PHI nodes in block #15