/var/lib/pcp/testsuite/521 is in pcp-testsuite 3.8.12ubuntu1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | #!/bin/sh
# PCP QA Test No. 521
# pmie unit scale factors and predefined macro tests
#
# Copyright (c) 2012 Ken McDonell. All Rights Reserved.
#
seq=`basename $0`
echo "QA output created by $seq"
# get standard environment, filters and checks
. ./common.product
. ./common.filter
. ./common.check
status=1 # failure is the default!
$sudo rm -rf $tmp.* $seq.full
trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
_filter()
{
sed \
-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/' \
-e 's/DATE [12][0-9][0-9][0-9]/DATE/' \
-e '/evaluator exiting/s/pmie([0-9][0-9]*)/pmie(PID)/' \
-e '/Performance Co-Pilot Inference Engine/s/Version .*/Version .../' \
-e '/^raw_/d'
}
cat <<'End-of-File' >$tmp.pmie
// scale factors
nanosecond_microsecond = sample.long.hundred * 10nanosecond == 1microsecond;
nanosec_microsec = sample.long.hundred * 10 nanosec == 1 microsec;
nsec_usec = sample.long.hundred * 10nsec == 1usec;
millisecond_second = sample.long.ten * 100millisecond == 1second;
millisec_sec = sample.long.ten * 100 millisec == 1 sec;
msec_min = sample.long.ten * 600msec == 6sec;
second_minute = sample.long.one * 1second == 1minute / 60;
sec_min = sample.long.one * 1 sec == 1 min / 60;
hour_min = sample.long.one * 1 hour == 60 min;
byte_Kbyte = sample.long.one * 1024 byte == 1 Kbyte;
Mbyte_Gbyte = sample.long.one * 1024 Mbyte == 1 Gbyte;
Gbyte_Tbyte = sample.long.one * 1024 Gbyte == 1 Tbyte;
count_Kcount = sample.long.one * 1000 count == 1 Kcount;
Kcount_Mcount = sample.long.one * 1Kcount == 1Mcount/1000;
// predefined macros
raw_minute_macro = $minute;
minute_macro = ($minute >= 00) && ($minute <= 59);
raw_hour_macro = $hour;
hour_macro = ($hour >= 00) && ($hour <= 23);
raw_day_macro = $day;
day_macro = ($day >= 1) && ($day <= 31);
raw_day_of_week_macro = $day_of_week;
day_of_week_macro = ($day_of_week >= 0) && ($day_of_week <= 6);
raw_year_macro = $year;
year_macro = $year > 2012;
raw_delta_macro = $delta;
delta_macro = $delta == 0.5;
End-of-File
# real QA test starts here
pmie -c $tmp.pmie -t 500msec -T900msec -v >$tmp.out 2>$tmp.err
echo "=== pmie output ===" >>$seq.full
cat $tmp.out >>$seq.full
echo >>$seq.full
echo "=== pmie errors ===" >>$seq.full
cat $tmp.err >>$seq.full
_filter <$tmp.err
_filter <$tmp.out
# success, all done
status=0
exit
|