summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/valgrind
diff options
context:
space:
mode:
authorRandy MacLeod <randy.macleod@windriver.com>2021-12-29 17:37:30 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-01-04 23:14:05 +0000
commit50d144b655b1677bf98faa9517f3a9701a8088b1 (patch)
tree496e384dc243ff331316fd9c2c59836571000f09 /meta/recipes-devtools/valgrind
parent521094d569d8d5542a5362421325bf71340d52c9 (diff)
downloadpoky-50d144b655b1677bf98faa9517f3a9701a8088b1.tar.gz
valgrind: make run-ptest better
There were warnings about non-existent files when there was a duplicate in the remove-for-aarch list and the non-deterministic lists so check if the files still exists before trying to deal with it. Also restore the tests in the opposite order that they were hidden. (From OE-Core rev: 2e1dc5782dcb879410d535f937c633edea484d11) Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/valgrind')
-rwxr-xr-xmeta/recipes-devtools/valgrind/valgrind/run-ptest23
1 files changed, 14 insertions, 9 deletions
diff --git a/meta/recipes-devtools/valgrind/valgrind/run-ptest b/meta/recipes-devtools/valgrind/valgrind/run-ptest
index caeae84d4f..15cf03f9d2 100755
--- a/meta/recipes-devtools/valgrind/valgrind/run-ptest
+++ b/meta/recipes-devtools/valgrind/valgrind/run-ptest
@@ -32,13 +32,16 @@ if [ "$arch" = "aarch64" ]; then
32 done 32 done
33fi 33fi
34 34
35echo "Run flaky tests using taskset to limit them to a single core." 35echo "Run non-deterministic tests using taskset to limit them to a single core."
36for i in `cat taskset_nondeterministic_tests`; do 36for i in `cat taskset_nondeterministic_tests`; do
37 taskset 0x00000001 perl tests/vg_regtest --valgrind=${VALGRIND_BIN} --valgrind-lib=${VALGRIND_LIBEXECDIR} --yocto-ptest $i 2>&1|tee -a ${LOG} 37 # The remove-for-aarch64 and taskset_nondeterministic_tests may overlap so
38 mv $i.vgtest $i.IGNORE 38 # check if a file exist.
39 if test -f "${i}.vgtest"; then
40 taskset 0x00000001 perl tests/vg_regtest --valgrind=${VALGRIND_BIN} --valgrind-lib=${VALGRIND_LIBEXECDIR} --yocto-ptest $i 2>&1|tee -a ${LOG}
41 mv $i.vgtest $i.IGNORE
42 fi
39done 43done
40 44
41
42cd ${VALGRIND_LIB}/ptest && ./tests/vg_regtest \ 45cd ${VALGRIND_LIB}/ptest && ./tests/vg_regtest \
43 --valgrind=${VALGRIND_BIN} \ 46 --valgrind=${VALGRIND_BIN} \
44 --valgrind-lib=${VALGRIND_LIBEXECDIR} \ 47 --valgrind-lib=${VALGRIND_LIBEXECDIR} \
@@ -51,6 +54,13 @@ cd ${VALGRIND_LIB}/ptest && \
51 gdbserver_tests ${TOOLS} ${EXP_TOOLS} \ 54 gdbserver_tests ${TOOLS} ${EXP_TOOLS} \
52 2>&1|tee -a ${LOG} 55 2>&1|tee -a ${LOG}
53 56
57echo "Restore non-deterministic tests"
58for i in `cat taskset_nondeterministic_tests`; do
59 if test -f "${i}.vgtest.IGNORE"; then
60 mv $i.IGNORE $i.vgtest;
61 fi
62done
63
54if [ "$arch" = "aarch64" ]; then 64if [ "$arch" = "aarch64" ]; then
55 echo "Aarch64: Restore valgrind tests that result in defunct process and then out of memory" 65 echo "Aarch64: Restore valgrind tests that result in defunct process and then out of memory"
56 for i in `cat remove-for-aarch64`; do 66 for i in `cat remove-for-aarch64`; do
@@ -63,11 +73,6 @@ for i in `cat remove-for-all`; do
63 mv $i.IGNORE $i.vgtest; 73 mv $i.IGNORE $i.vgtest;
64done 74done
65 75
66echo "Restore flaky and other non-deterministic tests"
67for i in `cat taskset_nondeterministic_tests`; do
68 mv $i.IGNORE $i.vgtest;
69done
70
71echo "Failed test details..." 76echo "Failed test details..."
72failed_tests=`grep FAIL: ${LOG} | awk '{print $2}'` 77failed_tests=`grep FAIL: ${LOG} | awk '{print $2}'`
73for test in $failed_tests; do 78for test in $failed_tests; do