aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorChristophe Lyon <christophe.lyon@linaro.org>2015-10-15 14:44:12 +0200
committerChristophe Lyon <christophe.lyon@linaro.org>2015-10-15 14:44:12 +0200
commitefd6e09df19c782c553ee6afb363ffb84353e166 (patch)
tree30115e60e8fd5015afcaf5ca308635e47dc1144c /scripts
parentfcebab993c071556b394a29fff5cc8e3dbbd896c (diff)
Fix bug #1845.
To distinguish tests with the same name in different components, prefix the test names with the component name. This happens for instance with tests common to gcc and g++. Since we concatenate all the .sum files before comparison, the compare_dg_tests.pl script could be confused by multiple occurrences of the same test. With this patch, such tests will be prefixed by 'gcc:' or 'g++:', eg: gcc:c-c++-common/asan/swapcontext-test-1.c Change-Id: I846a3f96dd9f272394e9814b5be53964ffb462db
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/compare_tests11
1 files changed, 8 insertions, 3 deletions
diff --git a/scripts/compare_tests b/scripts/compare_tests
index 6eb0f1f6..4c72c6fd 100755
--- a/scripts/compare_tests
+++ b/scripts/compare_tests
@@ -97,9 +97,14 @@ if [ -d "$1" -a -d "$2" ] ; then
cmnsums=`cat $lst5 | wc -l`
echo "# Comparing $cmnsums common sum files:"
cat $lst5
- ( for fname in `cat $lst5`; do xzcat $1/$fname | sed -r 's:of file /home.*/gcc/:of file :;s:==[0-9]+==:==X==:;s/output pattern test,.*$/output pattern XXX/'; done ) >$sum1
- ( for fname in `cat $lst5`; do xzcat $2/$fname | sed -r 's:of file /home.*/gcc/:of file :;s:==[0-9]+==:==X==:;s/output pattern test,.*$/output pattern XXX/'; done ) >$sum2
- # At some point, we'll add --no-unstable --unstable-test=${my_path}/unstable-tests.txt
+ ( for fname in `cat $lst5`; do
+ bname=`basename $fname .sum.xz`
+ xzcat $1/$fname | sed -e "s/^\([A-Z]*: \)/\1 $bname:/" | sed -r 's:of file /home.*/gcc/:of file :;s:==[0-9]+==:==X==:;s/output pattern test,.*$/output pattern XXX/'
+ done ) >$sum1
+ ( for fname in `cat $lst5`; do
+ bname=`basename $fname .sum.xz`
+ xzcat $2/$fname | sed -e "s/^\([A-Z]*: \)/\1 $bname:/" | sed -r 's:of file /home.*/gcc/:of file :;s:==[0-9]+==:==X==:;s/output pattern test,.*$/output pattern XXX/'
+ done ) >$sum2
if [ "x${target}" != "x" ] ; then
unstable_target="--unstable-marker ${target}"
fi