[Bug tree-optimization/107153] [13 Regression] ICE in check_loop_closed_ssa_def, at tree-ssa-loop-manip.cc:645

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Oct 7 08:29:11 GMT 2022


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107153

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
OK, so the main issue is that when we parallelize a loop without stores we
insert stores and thus would require a loop PHI for the virtual operand plus
LC SSA updates.

We eventually end up in gen_parallel_loop at

      /* We assume that the loop usually iterates a lot.  */
      loop_version (loop, many_iterations_cond, NULL,
                    profile_probability::likely (),
                    profile_probability::unlikely (),
                    profile_probability::likely (),
                    profile_probability::unlikely (), true);
      update_ssa (TODO_update_ssa_no_phi);

which performs the update but doesn't insert PHIs - the above assumed
that we'd have no SSA update pending before the call to loop_version.

separate_decls_in_region is what creates the stores (with no virtual
operands, thus triggering renaming and the need for a LC PHI).

I'm going to work around.


More information about the Gcc-bugs mailing list