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

--- Comment #13 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Andrew Macleod <amacl...@gcc.gnu.org>:

https://gcc.gnu.org/g:f884c133dde519b4d8fc89f2f151711d1b0eb368

commit r13-5449-gf884c133dde519b4d8fc89f2f151711d1b0eb368
Author: Andrew MacLeod <amacl...@redhat.com>
Date:   Mon Jan 16 15:02:51 2023 -0500

    Correctly detect shifts out of range

    get_shift_range was incorrectly communicating that it couldn't calculate
    a range when the shift values was always out fo range.  Fix this and
    alwasy return [0, 0] when the shift value is always out of range.

            PR tree-optimization/108306
            gcc/
            * range-op.cc (operator_lshift::fold_range): Return [0, 0] not
            varying for shifts that are always out of void range.
            (operator_rshift::fold_range): Return [0, 0] not
            varying for shifts that are always out of void range.

            gcc/testsuite/
            * gcc.dg/pr108306.c: New.

Reply via email to