[Bug tree-optimization/106027] [11/12/13 Regression] ICE: 'verify_gimple' failed (error: mismatching comparison operand types) since r11-2450-g10231958fcfb13bc

cvs-commit at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Jun 20 13:02:21 GMT 2022


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

--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Biener <rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:713f2fd923442b1be620a44240ddf786ae0ab476

commit r13-1174-g713f2fd923442b1be620a44240ddf786ae0ab476
Author: Richard Biener <rguenther@suse.de>
Date:   Mon Jun 20 13:40:50 2022 +0200

    middle-end/106027 - fix types in needle folding

    The fold_to_nonsharp_ineq_using_bound folding ends up creating invalid
    typed IL which confuses later foldings.  The following fixes that.

    2022-06-20  Richard Biener  <rguenther@suse.de>

            PR middle-end/106027
            * fold-const.cc (fold_to_nonsharp_ineq_using_bound): Use the
            type of the prevailing comparison for the new comparison type.
            (fold_binary_loc): Use proper types for the A < X && A + 1 > Y
            to A < X && A >= Y folding.

            * gcc.dg/pr106027.c: New testcase.


More information about the Gcc-bugs mailing list