summaryrefslogtreecommitdiffstats
path: root/clang
diff options
context:
space:
mode:
authorNuno Lopes <nunoplopes@sapo.pt>2008-09-04 18:33:57 +0000
committerNuno Lopes <nunoplopes@sapo.pt>2008-09-04 18:33:57 +0000
commit92c4bc887372d7a1fa478d2f04ad44a645a2cf0a (patch)
tree09633a16c5c8392853045975a3211959adf8a182 /clang
parentfe1bb7964c718cbf7c56d5bfe187114128c48d79 (diff)
downloadbcm5719-llvm-92c4bc887372d7a1fa478d2f04ad44a645a2cf0a.tar.gz
bcm5719-llvm-92c4bc887372d7a1fa478d2f04ad44a645a2cf0a.zip
fix running tests with valgrind (there were a lot of bogus failures and warnings)
currently clang passes all tests under valgrind with the leak checker disabled :P (and fails most otherwise) llvm-svn: 55782
Diffstat (limited to 'clang')
-rwxr-xr-xclang/test/TestRunner.sh13
1 files changed, 7 insertions, 6 deletions
diff --git a/clang/test/TestRunner.sh b/clang/test/TestRunner.sh
index 455674cc025..09b73d2183b 100755
--- a/clang/test/TestRunner.sh
+++ b/clang/test/TestRunner.sh
@@ -46,20 +46,20 @@ if [ ! -n "$CLANG" ]; then
CLANG="clang"
fi
if [ -n "$VG" ]; then
- rm -f $OUTPUT.vg.*
- CLANG="valgrind --leak-check=full --quiet --log-file=$OUTPUT.vg.%p $CLANG"
+ rm -f $OUTPUT.vg
+ CLANG="valgrind --leak-check=full --quiet --log-file=$OUTPUT.vg $CLANG"
fi
SCRIPT=$OUTPUT.script
TEMPOUTPUT=$OUTPUT.tmp
grep 'RUN:' $FILENAME | \
sed -e "s|^.*RUN:\(.*\)$|\1|g" \
+ -e "s|clang|$CLANG|g" \
-e "s|%s|$SUBST|g" \
-e "s|%llvmgcc|llvm-gcc -emit-llvm|g" \
-e "s|%llvmgxx|llvm-g++ -emit-llvm|g" \
-e "s|%prcontext|prcontext.tcl|g" \
- -e "s|%t|$TEMPOUTPUT|g" \
- -e "s|clang|$CLANG|g" > $SCRIPT
+ -e "s|%t|$TEMPOUTPUT|g" > $SCRIPT
IS_XFAIL=0
if (grep -q XFAIL $FILENAME); then
@@ -72,7 +72,8 @@ fi
SCRIPT_STATUS=$?
if [ -n "$VG" ]; then
- VG_STATUS=`cat $OUTPUT.vg.* | wc -l`
+ [ ! -s $OUTPUT.vg ]
+ VG_STATUS=$?
else
VG_STATUS=0
fi
@@ -99,7 +100,7 @@ if [ $SCRIPT_STATUS -ne 0 -o $VG_STATUS -ne 0 ]; then
cat $OUTPUT
if [ $VG_STATUS -ne 0 ]; then
echo "Valgrind Output:"
- cat $OUTPUT.vg.*
+ cat $OUTPUT.vg
fi
echo "******************** TEST '$TESTNAME' FAILED! ********************"
exit 1
OpenPOWER on IntegriCloud