GNU bug report logs -
#17512
Valgrind and regression tests?
Previous Next
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
G'day,
I would like to run the entire regression test for Grep (make check),
with Valgrind monitoring each invocation of grep etc, but with the
output going to a separate logfile. (I have run valgrind for a few
cases, but have not covered the entire spectrum of the regression
test rig.)
The file grep/README-hacking recommends using valgrind, and also
suggests that hackers look at the file "README-valgrind", but no such
file exists.
I note that Valgrind sends its output to stderr by default, and that
the option --log-file=<filename> exists to redirect Valgrind output
elsewhere. This would be needed in the case of grep et al, as stderr
is used in various ways by the programs.
Is there a simple way of incorporating valgrind into the entire
regression test run? Two simple ideas come to mind, but I'm not
well versed in the POSIX/shell/makefile/Autoconf/regression rig setup
to know how realistic these are:
1. Use a shell alias:
grep="valgrind --log-file=foo grep" make check
2. Replace grep/egrep/fgrep as appropriate to execute the program
within a shell, where valgrind plus any options is incorporated
into the program invocation and the logfile is treated
appropriately in the program invocation aftermath.
Any hints, help, suggestions etc would be welcome.
cheers,
behoffski (Brenton Hoff)
Programmer, Grouse Software
This bug report was last modified 11 years and 86 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.