I don't know what these notes are about so I put it in the issue :-) I found these in my local copy of the repo.
Memory checking using ctest
Basic setup
To quickly use memcheck with ctest, add include(CTest) instead of
#enable_testing(). Then use ctest as usually but add -T memcheck option.
This should execute each test with valgrind (I guess valgrind should be
installed first).
When ctest -T memcheck executed, the following output is possible when
memcheck finds problems. The valgrind details are in the log files.
...
-- Processing memory checking output:
62/62 MemCheck: #62: lgm_ub_lb_fill_gaps_test ....................................... Defects: 2
MemCheck log files can be found here: ( * corresponds to test number)
/home/mpawlik/Remote/tree-similarity/build/Testing/Temporary/MemoryChecker.*.log
Memory checking results:
Uninitialized Memory Read - 2
Errors while running CTest
Ignoring tests for memcheck
In CmakeLists.txt corresponding to tests to be ignored add:
I don't know what these notes are about so I put it in the issue :-) I found these in my local copy of the repo.
Memory checking using ctest
Basic setup
To quickly use memcheck with ctest, add
include(CTest)
instead of#enable_testing()
. Then use ctest as usually but add-T memcheck
option. This should execute each test with valgrind (I guess valgrind should be installed first).When
ctest -T memcheck
executed, the following output is possible when memcheck finds problems. The valgrind details are in the log files.Ignoring tests for memcheck
In
CmakeLists.txt
corresponding to tests to be ignored add:In file
CTestCustom.cmake
add tests to ignore when memcheck. I couldn't find a way to use regex here.Then, when executing
ctest
, specified tests will be ignored.Some test execution times
ctest
240 secctest -R ted_join_correctness_test_ -T memcheck
105 secctest -R ted_join_correctness_test_guhajoin
102 secctest -T memcheck
1361 secctest -R guha
107 sec