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

--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by David Malcolm <dmalc...@gcc.gnu.org>:

https://gcc.gnu.org/g:070523b9d4c6cfa69060255893006efaf39bf617

commit r13-6393-g070523b9d4c6cfa69060255893006efaf39bf617
Author: David Malcolm <dmalc...@redhat.com>
Date:   Wed Mar 1 08:54:43 2023 -0500

    analyzer: fix infinite recursion false +ves [PR108935]

    gcc/analyzer/ChangeLog:
            PR analyzer/108935
            * infinite-recursion.cc (contains_unknown_p): New.
            (sufficiently_different_region_binding_p): New function, splitting
            out inner loop from...
            (sufficiently_different_p): ...here.  Extend detection of unknown
            svalues to also include svalues that contain unknown.  Treat
            changes in frames below the entry to the recursion as being
            sufficiently different to reject being an infinite recursion.

    gcc/testsuite/ChangeLog:
            PR analyzer/108935
            * gcc.dg/analyzer/infinite-recursion-pr108935-1.c: New test.
            * gcc.dg/analyzer/infinite-recursion-pr108935-1a.c: New test.
            * gcc.dg/analyzer/infinite-recursion-pr108935-2.c: New test.

    Signed-off-by: David Malcolm <dmalc...@redhat.com>

Reply via email to