3 # pmie unit scale factors and predefined macro tests
5 # Copyright (c) 2012 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.
* $seq.full
18 trap "rm -f $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 .../' \
30 cat <<'End-of-File' >$tmp.pmie
32 nanosecond_microsecond = sample.long.hundred * 10nanosecond == 1microsecond;
33 nanosec_microsec = sample.long.hundred * 10 nanosec == 1 microsec;
34 nsec_usec = sample.long.hundred * 10nsec == 1usec;
35 millisecond_second = sample.long.ten * 100millisecond == 1second;
36 millisec_sec = sample.long.ten * 100 millisec == 1 sec;
37 msec_min = sample.long.ten * 600msec == 6sec;
38 second_minute = sample.long.one * 1second == 1minute / 60;
39 sec_min = sample.long.one * 1 sec == 1 min / 60;
40 hour_min = sample.long.one * 1 hour == 60 min;
41 byte_Kbyte = sample.long.one * 1024 byte == 1 Kbyte;
42 Mbyte_Gbyte = sample.long.one * 1024 Mbyte == 1 Gbyte;
43 Gbyte_Tbyte = sample.long.one * 1024 Gbyte == 1 Tbyte;
44 count_Kcount = sample.long.one * 1000 count == 1 Kcount;
45 Kcount_Mcount = sample.long.one * 1Kcount == 1Mcount/1000;
48 raw_minute_macro = $minute;
49 minute_macro = ($minute >= 00) && ($minute <= 59);
50 raw_hour_macro = $hour;
51 hour_macro = ($hour >= 00) && ($hour <= 23);
53 day_macro = ($day >= 1) && ($day <= 31);
54 raw_day_of_week_macro = $day_of_week;
55 day_of_week_macro = ($day_of_week >= 0) && ($day_of_week <= 6);
56 raw_year_macro = $year;
57 year_macro = $year > 2012;
58 raw_delta_macro = $delta;
59 delta_macro = $delta == 0.5;
62 # real QA test starts here
63 pmie
-c $tmp.pmie
-t 500msec
-T900msec -v >$tmp.out
2>$tmp.err
65 echo "=== pmie output ===" >>$seq.full
66 cat $tmp.out
>>$seq.full
68 echo "=== pmie errors ===" >>$seq.full
69 cat $tmp.err
>>$seq.full