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

--- Comment #8 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Biener <[email protected]>:

https://gcc.gnu.org/g:6b8c4689d99d36dc4e849a97bcf14b200d5d47cb

commit r17-6637-g6b8c4689d99d36dc4e849a97bcf14b200d5d47cb
Author: Richard Biener <[email protected]>
Date:   Tue Nov 24 16:26:42 2026 +0100

    tree-optimization/128482 - more UB with SCEV

    The following fixes more of the overflow cases accumulating
    CHREC_RIGHT by moving the PR125652/PR121370 fixes to a generic place
    where it also catches the CST - CHREC handling in chrec_fold_plus_1.

            PR tree-optimization/128482
            PR tree-optimization/125652
            PR tree-optimization/121370
            * tree-chrec.h (build_polynomial_chrec): Return
            chrec_dont_know when CHREC_RIGHT overflowed.  Moved
            from ...
            * tree-chrec.cc (chrec_fold_plus_poly_poly): ... here.
            * tree-scalar-evolution.cc (scev_dfs::add_to_evolution_1): ...
            and here.

            * gcc.dg/torture/pr128482-1.c: New testcase.
            * gcc.dg/torture/pr128482-2.c: Likewise.
            * gcc.dg/torture/pr128482-3.c: Likewise.

Reply via email to