How to combine memgrick Valgrind reports from multiple runs of the same process?

I have a set of acceptance tests that take place at night. I would like to use valgrind to automatically check for memory leaks in my code as an extra protection for manually checking for leaks. Updating my scripts to run my processes in valgrind is trivial, however, each test starts and stops several processes, and there are about 15,000 test cases, so I get thousands of separate reports.

Is there a tool that can combine these reports? I saw valkyrie, but according to the docs, they do not support valgrind 3.5

+3
source share
3 answers

If your code is mostly clean, you can just save the errors.

If you come back to a tool for combining outputs, then the original valgrind xml format might be right for a start. At least then the parsing should not be too complicated. You can also output the valgrind log to another file to separate it from program output. You can also get valgrind to give an error when it detects a memory leak with --error-exitcode=.

You still have to decide what is considered a memory leak when comparing leaks.

+1
source

--gen-suppressions=all concat . , , valgrind .

, , , , .

--quiet : . , .

0

Valkyrie ( GUI Valgrind) , .

$ man valkyrie
NAME
   valkyrie - graphical front-end to the Valgrind suite of tools for debugging and profiling Linux executables

SYNOPSIS
   valkyrie [valkyrie-opts] [valgrind-opts] [prog-and-args]

<snip> 
   --merge <loglist>
          Merge multiple logfiles, discarding duplicate errors

CLI, vk_logmerge. valkyrie, Ubuntu.

0

Source: https://habr.com/ru/post/1751672/


All Articles