This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
RUN_UNDER_VALGRIND statistics for GCC 7
- From: Martin LiÅka <mliska at suse dot cz>
- To: Jeff Law <law at redhat dot com>, Bernd Schmidt <bschmidt at redhat dot com>, Hans-Peter Nilsson <hp at bitrange dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 13 May 2016 15:04:42 +0200
- Subject: RUN_UNDER_VALGRIND statistics for GCC 7
- Authentication-results: sourceware.org; auth=none
- References: <564DDEF2 dot 8090803 at suse dot cz> <alpine dot BSF dot 2 dot 02 dot 1511202317130 dot 71916 at arjuna dot pair dot com> <5652DD92 dot 2030202 at suse dot cz> <56604E93 dot 5050805 at redhat dot com> <5666F723 dot 1030603 at suse dot cz> <5666F843 dot 9000004 at redhat dot com> <5666FF9A dot 2010306 at redhat dot com>
Hello.
I've tried to apply the same patch for the current trunk and tried to separate
reported errors to a different categories by a simple script ([1]).
There are number (complete report: [2]):
SECTION: gfortran
error types: 3534, total errors: 113282
error types: 90.15%, total errors: 27.11%
SECTION: c++
error types: 161, total errors: 7260
error types: 4.11%, total errors: 1.74%
SECTION: c
error types: 90, total errors: 6320
error types: 2.30%, total errors: 1.51%
SECTION: c-common
error types: 39, total errors: 205033
error types: 0.99%, total errors: 49.06%
SECTION: Other
error types: 96, total errors: 86037
error types: 2.45%, total errors: 20.59%
Type in the dump means a back trace, while 'total errors' represent total # of errors.
The second line shows a percentage ratio compared to all errors seen.
As seen fortran has very big variety of back traces. Well, it shows that we have multiple PRs reported,
they are references in the following PR: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68800
C++ FE looks quite good, same as C. c-common contains very interesting group:
are possibly lost: 204032 occurences
malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
xmalloc (xmalloc.c:148)
new_buff (lex.c:3158)
_cpp_get_buff (lex.c:3191)
cpp_create_reader(c_lang, ht*, line_maps*) (init.c:251)
c_common_init_options(unsigned int, cl_decoded_option*) (c-opts.c:219)
toplev::main(int, char**) (toplev.c:2070)
main (main.c:39)
(which is in fact majority of errors in the section). That's something I'm going to look at.
The last category (called Other) is dominated by
are definitely lost: 20740 occurences
calloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
xcalloc (xmalloc.c:163)
main (collect2.c:975)
which is probably option handling allocation stuff. Apart from that, there are just ~90 types of different
back traces. It's doable to remove majority of these in this stage1. OTOH as I'm not familiar with a FE (mainly Fortran),
solving Fortran FE would be not trivial.
Note: The dump comes from one week old build.
Martin
[1] https://github.com/marxin/script-misc/blob/master/valgrind-grep.py
[2] https://drive.google.com/open?id=0B0pisUJ80pO1M1VOd2pObUVXSEU