https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114736
--- Comment #12 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-13 branch has been updated by Richard Biener <rgue...@gcc.gnu.org>: https://gcc.gnu.org/g:0624852a3ea684f6b9dabea864bcb45e31304728 commit r13-8683-g0624852a3ea684f6b9dabea864bcb45e31304728 Author: Richard Biener <rguent...@suse.de> Date: Tue Apr 16 11:33:48 2024 +0200 tree-optimization/114736 - SLP DFS walk issue The following fixes a DFS walk issue when identifying to be ignored latch edges. We have (bogus) SLP_TREE_REPRESENTATIVEs for VEC_PERM nodes so those have to be explicitly ignored as possibly being PHIs. PR tree-optimization/114736 * tree-vect-slp.cc (vect_optimize_slp_pass::is_cfg_latch_edge): Do not consider VEC_PERM_EXPRs as PHI use. * gfortran.dg/vect/pr114736.f90: New testcase. (cherry picked from commit f949481a1f7ab973608a4ffcc0e342ab5a74e8e4)