jobs
3.22 KB
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
#!/bin/sh
# Please setup as:
# crontab -e
# Add line: minutes hour * * *
# 30 19 * * * /work/bb/rf/sw/bbplayer/tests/jobs
freq_8=`echo "1250 + $RANDOM % 750" | bc`
sys_period=`echo "$freq_8 * 8" | bc`
#sys_period=16000
v_period=69841
###############################################
#
# DAY Period Feq DDR
# Mon 16000 62.5 32
# Tue 10416 96 32
# Wed 16000 62.5 16
# Thu Random Random 32
# Fri 12000 83.3 16
# Sat 16000 62.5 32
# Sun 10664 93.75 32
#
ddd=`date +%w`
DDROPTS="on 16bits DDR"
BBDDR=""
case $ddd in
2) sys_period=16000; DDROPTS="on 32bits DDR";;
1) sys_period=10416; DDROPTS="on 32bits DDR";;
3) sys_period=16000; export BBDDR="+define+DDR32M16";;
4) DDROPTS="on 32bits DDR";;
5) sys_period=12000; export BBDDR="+define+DDR32M16";;
6) sys_period=16000; DDROPTS="on 32bits DDR";;
0) sys_period=10664; DDROPTS="on 32bits DDR";;
esac
export BBOPTS="+sysclk=${sys_period} +vclk=${v_period}"
sys_clk=`echo "scale=1; 1000000/$sys_period" | bc`
v_clk=`echo "scale=1; 1000000/$v_period" | bc`
LOG=`date +%Y%m%d`
SUB1=`date +%Y-%m-%d`
SUB="${SUB1} nightly regression results $DDROPTS"
SUBPERF="${SUB1} nightly regression performance results $DDROPTS"
. /home/whs/bb/setup
BB_PATH=/home/whs/bb/rf/sw/root/PR
cd ${BB_PATH}/tests
echo "Nightly regression run at sysclk=${sys_clk}MHz(${sys_period}) vclk=${v_clk}MHz $DDROPTS" > ${LOG}.result
echo "<html><h1>Nightly regression Performance measured at sysclk=${sys_clk}MHz vclk=${v_clk}MHz</h1> $DDROPTS" > ${LOG}.perf.html
echo "Nightly regression Performance measured at sysclk=${sys_clk}MHz vclk=${v_clk}MHz" > /tmp/bb_perf
echo "* * * Performance Measure at `date` on `hostname` * * * " >> /tmp/bb_perf
echo "* * * Performance Measure at `date` on `hostname` * * * " >> ${LOG}.perf.html
cvs update . >> ${LOG}.update
./nightly /home/whs/bb/rf/sw/root/PR/tests/${LOG} >> ${LOG}.log 2>&1
#### Create Performance comparison #########
cd ${BB_PATH}/tests/perf
./perf /tmp/bb_perf ../${LOG}.perf.html
echo "</html>" >> ../${LOG}.perf.html
mv -f /tmp/bb_perf ../${LOG}.perf
##################################
##################################
# Export information to web server
#
machine=source.routefree.com
now="$LOG"
topdir=/home/httpd/html
###################################
# Process the coverage information
#
cd ${BB_PATH}/hw2/chip/vsim
cmView -b +DIR=sim.ipc.cm
dirname=${topdir}/bb_chip_coverage/${now}
rsh -n ${machine} mkdir ${dirname}
rcp sim.ipc.cm/reports/cmView* ${machine}:${dirname}
rsh -n ${machine} rm -f ${topdir}/bb_chip_coverage/latest
rsh -n ${machine} ln -s ${dirname} ${topdir}/bb_chip_coverage/latest
###################################
# Archive the results
#
cd ${BB_PATH}/tests
dirname=${topdir}/bb_chip_regression/${now}
rsh -n ${machine} mkdir ${dirname}
rcp ${now}.* ${machine}:${dirname}
rsh -n ${machine} rm -f ${topdir}/bb_chip_regression/latest
rsh -n ${machine} ln -s ${dirname} ${topdir}/bb_chip_regression/latest
##### Mail result out
echo "Sender: whs@broadon.com" > rr.$$
echo "From: whs@broadon.com" >> rr.$$
echo "To: bb-dv@routefree.com" >> rr.$$
echo "Subject: ${SUB}" >> rr.$$
cat /home/whs/bb/rf/sw/root/PR/tests/${LOG}.result >> rr.$$
/usr/lib/sendmail -v -U bb-dv@routefree.com < rr.$$
rm -rf rr.$$
rm -rf tmp.*