diff options
author | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-05-04 05:48:56 +0000 |
---|---|---|
committer | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-05-04 05:48:56 +0000 |
commit | e6e189fa270c5aa4aa168eef3935aa7e40f30175 (patch) | |
tree | a92ff5b1a65fe78279e0fd8b82fac273d28a6181 /contrib/dg-extract-results.sh | |
parent | 469cf0eb8ebe007ed2ed6d9b694396fb8216f80b (diff) | |
download | gcc-e6e189fa270c5aa4aa168eef3935aa7e40f30175.tar.gz |
2009-05-04 Basile Starynkevitch <basile@starynkevitch.net>
MELT branch merged with trunk r147090
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@147091 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'contrib/dg-extract-results.sh')
-rwxr-xr-x | contrib/dg-extract-results.sh | 29 |
1 files changed, 18 insertions, 11 deletions
diff --git a/contrib/dg-extract-results.sh b/contrib/dg-extract-results.sh index 75ae38f70e8..518c19f6bee 100755 --- a/contrib/dg-extract-results.sh +++ b/contrib/dg-extract-results.sh @@ -6,7 +6,7 @@ # The resulting file can be used with test result comparison scripts for # results from tests that were run in parallel. See usage() below. -# Copyright (C) 2008 Free Software Foundation +# Copyright (C) 2008, 2009 Free Software Foundation # Contributed by Janis Johnson <janis187@us.ibm.com> # # This file is part of GCC. @@ -148,26 +148,28 @@ if [ "$TOOL" = acats ]; then ACATS_AWK=${TMP}/acats.awk cat <<EOF > $ACATS_AWK BEGIN { - print_prologue=1; chapter=""; insummary=0 + print_prologue=1; curfile=""; insummary=0 passcnt=0; failcnt=0; unsupcnt=0; failures="" } -/=== acats configuration ===/ { +/^[ \t]*=== acats configuration ===/ { insummary=0 if (print_prologue) print next } -/=== acats tests ===/ { +/^[ \t]*=== acats tests ===/ { if (print_prologue) print print_prologue=0 next } /^Running chapter / { - chapter=\$3 - print > "${TMP}/chapter-"chapter + if (curfile) close (curfile) + curfile="${TMP}/chapter-"\$3 + print >> curfile next } -/=== acats Summary ===/ { - chapter="" +/^[ \t]*=== acats Summary ===/ { + if (curfile) close (curfile) + curfile="" insummary=1 next } @@ -182,7 +184,7 @@ BEGIN { } { if (print_prologue) { print; next } - if (chapter) print > "${TMP}/chapter-"chapter + if (curfile) print >> curfile } END { system ("cat ${TMP}/chapter-*") @@ -194,6 +196,7 @@ END { } EOF + rm -f ${TMP}/chapter-* $AWK -f $ACATS_AWK $SUM_FILES exit 0 fi @@ -270,6 +273,7 @@ BEGIN { expfileno=1 cnt=0 print_using=0 + need_close=0 } /^EXPFILE: / { expfiles[expfileno] = \$2 @@ -287,8 +291,10 @@ BEGIN { /^Running / { print_using=0 if (variant == curvar) { + if (need_close) close(curfile) curfile="${TMP}/list"expfilesr[\$2] expfileseen[\$2]=expfileseen[\$2] + 1 + need_close=0 testname="00" next } @@ -303,11 +309,12 @@ BEGIN { /^$/ { if ("$MODE" == "sum") next } { if (variant == curvar && curfile) { if ("$MODE" == "sum") { - printf "%s %08d|", testname, cnt > curfile + printf "%s %08d|", testname, cnt >> curfile cnt = cnt + 1 } filewritten[curfile]=1 - print > curfile + need_close=1 + print >> curfile } else next } |