[Bug tree-optimization/83044] [8 Regression] ice in contains_struct_check

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Nov 22 12:36:00 GMT 2017


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

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Wed Nov 22 12:35:26 2017
New Revision: 255054

URL: https://gcc.gnu.org/viewcvs?rev=255054&root=gcc&view=rev
Log:
        PR tree-optimization/83044
        * tree-vrp.c (vrp_prop::check_array_ref): If eltsize is not
        INTEGER_CST or is 0, clear up_bound{,_p1} and later ignore tests
        that need the upper bound.  Subtract offset from
        get_addr_base_and_unit_offset only if positive and subtract it
        before division by eltsize rather than after it.

        * gcc.dg/pr83044.c: New test.
        * c-c++-common/Warray-bounds.c (fb): Fix up MAX value.

Added:
    trunk/gcc/testsuite/gcc.dg/pr83044.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/c-c++-common/Warray-bounds.c
    trunk/gcc/tree-vrp.c


More information about the Gcc-bugs mailing list