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

--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Aldy Hernandez <al...@gcc.gnu.org>:

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

commit r12-5242-ga7ef5da3a9c348c35abb72d6f64f209f5661cfa4
Author: Aldy Hernandez <al...@redhat.com>
Date:   Sun Nov 14 11:27:32 2021 +0100

    Do not pass NULL to memset in ssa_global_cache.

    The code computing ranges in PHIs in the path solver reuses the
    temporary ssa_global_cache by calling its clear method.  Calling it on
    an empty cache causes us to call memset with NULL.

    Tested on x86-64 Linux.

    gcc/ChangeLog:

            PR tree-optimization/103229
            * gimple-range-cache.cc (ssa_global_cache::clear): Do not pass
            null value to memset.

    gcc/testsuite/ChangeLog:

            * gcc.dg/pr103229.c: New test.

Reply via email to