nightly.clean
5.57 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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
#!/bin/sh
#
# set tabsbtop=4
RST=`pwd`/`basename $1`.result
UPD=`pwd`/`basename $1`.update
echo "* * * Test run on `hostname` at `pwd` * * *" >> $RST
if [ "$SNPSLMD_LICENSE_FILE" = "" ]; then
echo "#################################################" >> $RST
echo "Test Failed : Please setup vcs environment first" >> $RST
echo "#################################################" >> $RST
exit 1
fi
cd ..
BB_PATH=`pwd`
######## update libbcppli #######
cd ${BB_PATH}/lib/libbcppli
#cvs update -df >> $UPD 2>&1
make
######## update sim.ipc #########
cd ${BB_PATH}/hw2
#cvs update -df >> $UPD 2>&1
cd chip/vsim
make sim.ipc > /dev/null 2>&1 || {
echo "Make sim.ipc Failed" >> $RST
}
echo "+ + + Nightly Test Start(component level) + + +" >> $RST
date >> $RST
######## Component level test come first ##########
#### VI component
cd ${BB_PATH}/rdpsim/test/vi
make rtests > result 2>&1
grep errors result | grep -v "errors:[[:space:]]*0" && {
echo "Failed: vi componet level error" >> $RST
echo "please check file: ${BB_PATH}/rdpsim/test/vi/result" >> $RST
}
grep ERROR result | grep -v "NO ERRORS" && {
echo "Failed: vi componet level error" >> $RST
echo "please check file: ${BB_PATH}/rdpsim/test/vi/result" >> $RST
}
#RSP test
cd $BB_PATH
cd rspsim/vuregre
make clean
# SU TEST
make su >/dev/null 2>&1
grep "Failed :0" rsptest/SUTest/regression.log /dev/null 2>&1 && {
echo "BCP rsp SU test passed" >> $RST
} || {
echo "ERROR: BCP rsp SU test Failed" >> $RST
echo "please refer to ${cur_path}/rsp/rspsim/vuregre/rsptest/SUTest/regression.log" >> $RST
}
# SU SINGLE STEP TEST
make su_single >/dev/null 2>&1
grep "Failed :0" rsptest/SUTestSingle/regression.log /dev/null 2>&1 && {
echo "BCP rsp SU SINGLE STEP test passed" >> $RST
} || {
echo "ERROR: BCP rsp SU SINGLE_STEP test Failed" >> $RST
echo "please refer to ${cur_path}/rsp/rspsim/vuregre/rsptest/SUTestSingle/regression.log" >> $RST
}
# VU TEST
make vu >/dev/null 2>&1
grep "Failed :0" rsptest/VUTest/regression.log /dev/null 2>&1 && {
echo "BCP rsp VU test passed" >> $RST
} || {
echo "ERROR: BCP rsp VU test Failed"
echo "please refer to ${cur_path}/rsp/rspsim/vuregre/rsptest/VUTest/regression.log" >> $RST
}
# VU SINGLE STEP TEST
make vu_single >/dev/null 2>&1
grep "Failed :0" rsptest/VUTestSingle/regression.log > /dev/null 2>&1 && {
echo "BCP rsp VU Single step test passed" >> $RST
} || {
echo "ERROR: BCP rsp VU single step test Failed" >> $RST
echo "please refer to ${cur_path}/rsp/rspsim/vuregre/rsptest/VUTestSingle/regression.log" >> $RST
}
export IOSIM_SERVER=127.0.0.1
export IOSIM_PORT=6767
###### check out new iosim tests ######
cd ${BB_PATH}/include
#cvs update -df >>$UPD 2>&1
make headers
cd ${BB_PATH}/iosim
#cvs update -df >>$UPD 2>&1
cd src
make
###### START SIM.IPC ########
cd ${BB_PATH}/hw2/chip/vsim
./sim.ipc +vcs+lic+wait &
cd ${BB_PATH}/tests
echo "+ + + Nightly Test Start(base on ipc simulator) + + +" >> $RST
date >> $RST
../iosim/src/iosim -f ../iosim/test/bcp_init.tst
# IOSIM AI test
echo
echo "Start BCP AI test "
../iosim/src/iosim -f ../iosim/test/bcp_ai.tst > tmp.$$ 2>&1
grep -i "Fail" tmp.$$ && {
echo "AI IOSIM test failed" >> $RST
} || {
echo "AI IOSIM test passed" >> $RST
}
cat tmp.$$
#IOSIM ri test
../iosim/src/iosim -f ../iosim/test/bcp_ri.tst > tmp.$$ 2>&1
grep -i "Fail" tmp.$$ && {
echo "RI IOSIM test failed" >> $RST
} || {
echo "RI IOSIM test passed" >> $RST
}
cat tmp.$$
#IOSIM sp test
../iosim/src/iosim -f ../iosim/test/bcp_sp.tst > tmp.$$ 2>&1
grep -i "Fail" tmp.$$ && {
echo "SP IOSIM test failed" >> $RST
} || {
echo "SP IOSIM test passed" >> $RST
}
cat tmp.$$
rm -rf tmp
##### Iosim Vi test ######
### 3 test failed
[ -d ${BB_PATH}/rdpsim/backend/test/Iosim/OutData ] || {
mkdir -p ${BB_PATH}/rdpsim/backend/test/Iosim/OutData
}
cd ${BB_PATH}/rdpsim/backend/test/Iosim/OutData
rm -rf *
cd ..
make clean
make allvi_clean
grep -v equate OutData/Results && {
echo "Failed: Vi iosim test error." >> $RST
} || {
echo "VI IOSIM test passed" >> $RST
}
##### rsp iosim test ######
# dma pin pin_single
#
cd $BB_PATH
cd rspsim/vuregre
# DMA TEST
make dma >/dev/null 2>&1
grep "Failed" rsptest/dmatest/test.result > /dev/null 2>&1 && {
echo "ERROR: BCP rsp DMA test Failed" >> $RST
} || {
echo "BCP rsp DMA test passed" >> $RST
}
# PIN TEST
make pin >/dev/null 2>&1
grep "Failed" rsptest/pinTest/test.result > /dev/null 2>&1 && {
echo "ERROR: BCP rsp PIN test Failed" >> $RST
} || {
echo "BCP rsp PIN test passed" >> $RST
}
# PIN SINGLE STEP TEST
make pin_single >/dev/null 2>&1
grep "Failed" rsptest/pinTestSingle/test.result > /dev/null 2>&1 && {
echo "ERROR: BCP rsp pin Single step test Failed" >> $RST
} || {
echo "BCP rsp PIN Single step test passed" >> $RST
}
cd $BB_PATH/iosim
./src/iosim -f ./test/bcp_quit.tst
###### VI iorand test
cd $BB_PATH
cd iosim/data/dma80
make >/dev/null 2>&1
make vitest > test.result 2>&1
count=`grep "total error = 0" test.result | wc -l`
if [ $count -eq 6 ]; then
echo "VI IORAND test passed" >> $RST
else
echo "ERROR: Vi IORAND test Failed" >> $RST
fi
##### rdp iosim test #####
# test039_tex cov bit failed
#
# Make dp test one by one again
#
cd ${BB_PATH}/rdpsim/test/rdp
rm -f Outdata/*.cov
rm -f Outdata/*.rgb
rm -f Outdata/*.z
rm -f result.diff
make nightly_rdp_io > result 2>&1
make image_diff_hwio >> result.diff
grep -i error result.diff | grep -v "ERROR: Image files OutData/test039_tex_hw_0.cov" && {
echo "Failed: rdp iosim error" >> $RST
} || {
echo "Succeed: rdp iosim test passed" >> $RST
}
echo "+ + + Nightly Test End + + +" >> $RST
date >> $RST