aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorEddie Hung <eddieh@ece.ubc.ca>2019-02-06 14:30:19 -0800
committerEddie Hung <eddieh@ece.ubc.ca>2019-02-06 14:30:19 -0800
commit3f87cf86ccefe6e66f768fbf19c34db97cf7246d (patch)
treec314d19a230dbe7d60bbc8c4714e39875d21feae /tests
parentfdd55d064b16f9334c86bb15b1c32cfb45294802 (diff)
downloadyosys-3f87cf86ccefe6e66f768fbf19c34db97cf7246d.tar.gz
yosys-3f87cf86ccefe6e66f768fbf19c34db97cf7246d.tar.bz2
yosys-3f87cf86ccefe6e66f768fbf19c34db97cf7246d.zip
Revert most of autotest.sh; for non *.v use Yosys to translate
Diffstat (limited to 'tests')
-rwxr-xr-xtests/tools/autotest.sh16
1 files changed, 9 insertions, 7 deletions
diff --git a/tests/tools/autotest.sh b/tests/tools/autotest.sh
index c01ce5611..3bce003e1 100755
--- a/tests/tools/autotest.sh
+++ b/tests/tools/autotest.sh
@@ -113,16 +113,18 @@ do
if [[ "$ext" == "v" ]]; then
egrep -v '^\s*`timescale' ../$fn > ${bn}_ref.${ext}
else
- cp ../$fn ${bn}_ref.${ext}
+ "$toolsdir"/../../yosys -f "$frontend $include_opts" -b "verilog" -o ${bn}_ref.v ../${fn}
+ frontend="verilog"
fi
if [ ! -f ../${bn}_tb.v ]; then
- "$toolsdir"/../../yosys -f "$frontend $include_opts" -b "test_autotb $autotb_opts" -o ${bn}_tb.v ${bn}_ref.${ext}
+ "$toolsdir"/../../yosys -f "$frontend $include_opts" -b "test_autotb $autotb_opts" -o ${bn}_tb.v ${bn}_ref.v
else
cp ../${bn}_tb.v ${bn}_tb.v
fi
if $genvcd; then sed -i 's,// \$dump,$dump,g' ${bn}_tb.v; fi
- compile_and_run ${bn}_tb_ref ${bn}_out_ref ${bn}_tb.v ${bn}_ref.v $libs
+ compile_and_run ${bn}_tb_ref ${bn}_out_ref ${bn}_tb.v ${bn}_ref.v $libs \
+ "$toolsdir"/../../techlibs/common/simlib.v
if $genvcd; then mv testbench.vcd ${bn}_ref.vcd; fi
test_count=0
@@ -143,16 +145,16 @@ do
fi
if [ -n "$scriptfiles" ]; then
- test_passes -f "$frontend $include_opts" ${bn}_ref.${ext} $scriptfiles
+ test_passes -f "$frontend $include_opts" ${bn}_ref.v $scriptfiles
elif [ -n "$scriptopt" ]; then
- test_passes -f "$frontend $include_opts" -p "$scriptopt" ${bn}_ref.${ext}
+ test_passes -f "$frontend $include_opts" -p "$scriptopt" ${bn}_ref.v
elif [ "$frontend" = "verific" ]; then
test_passes -p "verific -vlog2k ${bn}_ref.v; verific -import -all; opt; memory;;"
elif [ "$frontend" = "verific_gates" ]; then
test_passes -p "verific -vlog2k ${bn}_ref.v; verific -import -gates -all; opt; memory;;"
else
- test_passes -f "$frontend $include_opts" -p "hierarchy; proc; opt; memory; opt; fsm; opt -full -fine" ${bn}_ref.${ext}
- test_passes -f "$frontend $include_opts" -p "hierarchy; synth -run coarse; techmap; opt; abc -dff" ${bn}_ref.${ext}
+ test_passes -f "$frontend $include_opts" -p "hierarchy; proc; opt; memory; opt; fsm; opt -full -fine" ${bn}_ref.v
+ test_passes -f "$frontend $include_opts" -p "hierarchy; synth -run coarse; techmap; opt; abc -dff" ${bn}_ref.v
fi
touch ../${bn}.log
}