Skip to content

Commit bf32b9f

Browse files
committed
Add VCS to CI
1 parent ed39f90 commit bf32b9f

File tree

3 files changed

+112
-2
lines changed

3 files changed

+112
-2
lines changed

.gitlab-ci.yml

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ before_script:
55
- export PATH=~/.cargo/bin:$PATH
66
- mkdir -p build
77

8+
stages:
9+
- build
10+
- test
11+
812
vsim:
913
stage: build
1014
script:
@@ -179,3 +183,103 @@ axi_xbar:
179183
<<: *run_vsim
180184
variables:
181185
TEST_MODULE: axi_xbar
186+
187+
vcs_axi_addr_test:
188+
stage: test
189+
script:
190+
- make sim_vcs-axi_addr_test.log
191+
192+
vcs_axi_atop_filter:
193+
stage: test
194+
script:
195+
- make sim_vcs-axi_atop_filter.log
196+
197+
vcs_axi_cdc:
198+
stage: test
199+
script:
200+
- make sim_vcs-axi_cdc.log
201+
202+
vcs_axi_delayer:
203+
stage: test
204+
script:
205+
- make sim_vcs-axi_delayer.log
206+
207+
vcs_axi_dw_downsizer:
208+
stage: test
209+
script:
210+
- make sim_vcs-axi_dw_downsizer.log
211+
212+
vcs_axi_dw_upsizer:
213+
stage: test
214+
script:
215+
- make sim_vcs-axi_dw_upsizer.log
216+
217+
vcs_axi_fifo:
218+
stage: test
219+
script:
220+
- make sim_vcs-axi_fifo.log
221+
222+
vcs_axi_isolate:
223+
stage: test
224+
script:
225+
- make sim_vcs-axi_isolate.log
226+
227+
vcs_axi_iw_converter:
228+
stage: test
229+
script:
230+
- make sim_vcs-axi_iw_converter.log
231+
232+
vcs_axi_lite_regs:
233+
stage: test
234+
script:
235+
- make sim_vcs-axi_lite_regs.log
236+
237+
vcs_axi_lite_to_apb:
238+
stage: test
239+
script:
240+
- make sim_vcs-axi_lite_to_apb.log
241+
242+
vcs_axi_lite_to_axi:
243+
stage: test
244+
script:
245+
- make sim_vcs-axi_lite_to_axi.log
246+
247+
vcs_axi_lite_mailbox:
248+
stage: test
249+
script:
250+
- make sim_vcs-axi_lite_mailbox.log
251+
252+
vcs_axi_lite_xbar:
253+
stage: test
254+
script:
255+
- make sim_vcs-axi_lite_xbar.log
256+
257+
vcs_axi_modify_address:
258+
stage: test
259+
script:
260+
- make sim_vcs-axi_modify_address.log
261+
262+
vcs_axi_serializer:
263+
stage: test
264+
script:
265+
- make sim_vcs-axi_serializer.log
266+
267+
vcs_axi_sim_mem:
268+
stage: test
269+
script:
270+
- make sim_vcs-axi_sim_mem.log
271+
272+
vcs_axi_to_axi_lite:
273+
stage: test
274+
script:
275+
- make sim_vcs-axi_to_axi_lite.log
276+
277+
vcs_axi_to_mem_banked:
278+
stage: test
279+
script:
280+
- make sim_vcs-axi_to_mem_banked.log
281+
282+
vcs_axi_xbar:
283+
stage: test
284+
script:
285+
- make sim_vcs-axi_xbar.log

Makefile

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@ else
2323
VCS ?= vcs
2424
endif
2525

26+
# VCS_DEBUG ?= -debug_access+r
27+
VCS_DEBUG ?= -debug_access+nomemcbk
28+
VCS_XPROP ?= -xprop=xmerge
29+
VCS_OPT ?= $(VCS_XPROP) $(VCS_DEBUG) -full64 -CFLAGS \"-O4\" -O4 -j9
30+
2631
TBS ?= axi_addr_test \
2732
axi_atop_filter \
2833
axi_bus_compare \
@@ -103,7 +108,7 @@ compile_vcs.log: Bender.yml | build
103108

104109

105110
sim_vcs-%.log: compile_vcs.log
106-
export VCS="$(VCS)"; cd build && ../scripts/run_vcs.sh --random-seed $* | tee ../$@
111+
export VCS="$(VCS)"; export VCS_OPT="$(VCS_OPT)"; cd build && ../scripts/run_vcs.sh --random-seed $* | tee ../$@
107112
(! grep -n "Error" $@)
108113
(! grep -n "Fatal" $@)
109114

scripts/run_vcs.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,12 @@ ROOT=$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)
2222
SEEDS=(0)
2323

2424
call_vcs() {
25-
$VCS -Mlib=work-"${@: -1}" -Mdir=work-"${@: -1}" -debug_access+r -CFLAGS "-Os" -full64 -xprop=xmerge "$@"
25+
$VCS -Mlib=work-"${@: -1}" -Mdir=work-"${@: -1}" $VCS_OPT "$@"
2626
for seed in ${SEEDS[@]}; do
2727
echo
2828
echo "----"
2929
echo "Running with seed: $seed"
30+
echo "VCS options: $VCS_OPT"
3031
./"${@: -1}" +ntb_random_seed=$seed -exitstatus | tee "${@: -1}"_$seed.log 2>&1
3132
(! grep -n "Error" "${@: -1}"_$seed.log)
3233
(! grep -n "Fatal" "${@: -1}"_$seed.log)

0 commit comments

Comments
 (0)