https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114027
Robin Dapp <rdapp at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |rguenth at gcc dot gnu.org Last reconfirmed| |2024-2-22 Target|riscv |x86_64-*-* riscv*-*-* | |aarch64-*-* --- Comment #5 from Robin Dapp <rdapp at gcc dot gnu.org> --- To me it looks like we interpret e.g. c_53 = _43 ? prephitmp_13 : 0 as the only reduction statement and simplify to MAX because of the wrong assumption that this is the only reduction statement in the chain when we actually have several. (See "condition expression based on compile time constant"). --- Comment #6 from Robin Dapp <rdapp at gcc dot gnu.org> --- Btw this fails on x86 and aarch64 for me with -fno-vect-cost-model. So it definitely looks generic.