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

--- Comment #9 from CVS 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:db010f96743a4f289975a0432209c38ec34635e9

commit r13-8043-gdb010f96743a4f289975a0432209c38ec34635e9
Author: Richard Biener <rguent...@suse.de>
Date:   Thu Oct 12 09:09:46 2023 +0200

    tree-optimization/111764 - wrong reduction vectorization

    The following removes a misguided attempt to allow x + x in a reduction
    path, also allowing x * x which isn't valid.  x + x actually never
    arrives this way but instead is canonicalized to 2 * x.  This makes
    reduction path handling consistent with how we handle the single-stmt
    reduction case.

            PR tree-optimization/111764
            * tree-vect-loop.cc (check_reduction_path): Remove the attempt
            to allow x + x via special-casing of assigns.

            * gcc.dg/vect/pr111764.c: New testcase.

    (cherry picked from commit 05f98310b54da95e468d799f4a910174320cccbb)

Reply via email to