3 # pmie extensions for string-valued expressions
5 # Copyright (c) 2016 Ken McDonell. All Rights Reserved.
9 echo "QA output created by $seq"
11 # get standard environment, filters and checks
16 status
=1 # failure is the default!
17 $sudo rm -rf $tmp $tmp.
* $seq.full
18 trap "cd $here; rm -rf $tmp $tmp.*; exit \$status" 0 1 2 3 15
23 -e 's/[A-Z][a-z][a-z] [A-Z][a-z][a-z] *[0-9][0-9]* [0-9][0-9]:[0-9][0-9]:[0-9][0-9]/DATE/' \
24 -e 's/DATE [12][0-9][0-9][0-9]/DATE/' \
25 -e '/evaluator exiting/s/pmie([0-9][0-9]*)/pmie(PID)/' \
26 -e '/Performance Co-Pilot Inference Engine/s/Version .*/Version .../'
29 # mapping to 0x0 -> (nil) needed for C compilers that don't do the
30 # (nil) translation automatically for a printf %p
35 -e 's/0x0\([ (]\)/(nil)\1/g' \
39 $1 == "pmie:" { print; next }
40 /failed: / { print; next }
41 $1 == "bundle:" { skip=1 }
42 skip == 1 { if ($1 == "Rule:") skip = 0 }
45 tr ' =' '\012' <$tmp.tmp \
47 |
$PCP_AWK_PROG >$tmp.
sed '
49 { if (seen[$1] == 1) next
50 printf "s/%s/ADDR%03d/\n",$1,n
54 sed -f $tmp.
sed <$tmp.tmp
57 # real QA test starts here
58 echo "Error cases ..."
60 cat <<'End-of-File' >$tmp.pmie.00
61 sample.long.ten == "foo" -> print "blah";
66 echo |
tee -a $seq.full
67 echo "Test: `echo $x | sed -e "s
;$tmp.pmie.
;;"`" |
tee -a $seq.full
68 cat $x |
tee -a $seq.full
>>$seq.full
69 pmie
-Dappl0,appl1
-c $x -t 2 -T 1sec
>$tmp.out
2>$tmp.err
70 echo "=== pmie output ===" >>$seq.full
71 cat $tmp.out
>>$seq.full
73 echo "=== pmie errors ===" >>$seq.full
74 cat $tmp.err
>>$seq.full
76 _filter2
<$tmp.err | _filter