[Bug tree-optimization/95717] [9/10/11 Regression] ICE during GIMPLE pass: vect: verify_ssa failed since r9-5325-gf25507d041de4df6

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Jun 17 11:46:57 GMT 2020


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

--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
The bogus def is set via

  if (scalar_loop != loop)
    {
      /* If we copied from SCALAR_LOOP rather than LOOP, SSA_NAMEs from
         SCALAR_LOOP will have current_def set to SSA_NAMEs in the new_loop,
         but LOOP will not.  slpeel_update_phi_nodes_for_guard{1,2} expects
         the LOOP SSA_NAMEs (on the exit edge and edge from latch to
         header) to have current_def set, so copy them over.  */ 
      slpeel_duplicate_current_defs_from_edges (single_exit (scalar_loop),
                                                exit);

because that interferes with the renaming process.  The if-conversion
applied the missed optimization to the to-be vectorized loop introducing
a LC PHI (required for the not if-converted copy) which has one invariant
and one non-invariant arg.

So we have to do that copying after renaming in the BBs.  That seems to work,
testing patch.


More information about the Gcc-bugs mailing list