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

--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jorgen Kvalsvik <[email protected]>:

https://gcc.gnu.org/g:9c09713871ad6d05e1bd2bd65cb3c78c823cb42e

commit r17-4265-g9c09713871ad6d05e1bd2bd65cb3c78c823cb42e
Author: Jørgen Kvalsvik <[email protected]>
Date:   Tue Sep 15 16:04:12 2026 +0200

    Compare right field when printing summary

    The check

      if (coverage->calls && coverage->calls == 0)

    will always be false (as reported by -Wlogical-op) and broken.  I
    don't think there is a test suite for function summaries so this was
    not caught earlier.

    The logic is a bit awkward and could've been flipped to avoid checking
    calls_suppressed twice.  When it was written I wanted to minimize
    patch and preserve the "natural" order, since the suppression pragma
    is an opt-in, in a way.

            PR gcov-profile/127408

    gcc/ChangeLog:

            * gcov.cc (function_summary): Check calls_suppressed, not calls.

Reply via email to