diff options
author | Eddie Hung <eddieh@ece.ubc.ca> | 2019-02-19 15:25:03 -0800 |
---|---|---|
committer | Eddie Hung <eddieh@ece.ubc.ca> | 2019-02-19 15:25:03 -0800 |
commit | ef1a1402bcecd5cf3edc41b9842ab5500e52a95e (patch) | |
tree | 3fb3d3933c8b8b074afa46467b5fceed2c4495d9 | |
parent | 7b026c4bc316a44f2722cd4ddc96b4da1d1458b6 (diff) | |
download | yosys-ef1a1402bcecd5cf3edc41b9842ab5500e52a95e.tar.gz yosys-ef1a1402bcecd5cf3edc41b9842ab5500e52a95e.tar.bz2 yosys-ef1a1402bcecd5cf3edc41b9842ab5500e52a95e.zip |
Add a quick abc9 test
-rw-r--r-- | tests/techmap/abc9/abc9.v | 6 | ||||
-rw-r--r-- | tests/techmap/abc9/abc9_runtest.sh | 5 | ||||
-rwxr-xr-x | tests/techmap/abc9/run-test.sh | 10 | ||||
-rwxr-xr-x | tests/techmap/run-test.sh | 8 |
4 files changed, 29 insertions, 0 deletions
diff --git a/tests/techmap/abc9/abc9.v b/tests/techmap/abc9/abc9.v new file mode 100644 index 000000000..2d9aea366 --- /dev/null +++ b/tests/techmap/abc9/abc9.v @@ -0,0 +1,6 @@ +module top(input [1:0] a, output [1:0] b, output c, output d, output e); +assign b = a; +assign c = ^a; +assign d = ~c; +assign e = d; +endmodule diff --git a/tests/techmap/abc9/abc9_runtest.sh b/tests/techmap/abc9/abc9_runtest.sh new file mode 100644 index 000000000..2deaad719 --- /dev/null +++ b/tests/techmap/abc9/abc9_runtest.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +set -ev + +../../../yosys -p 'abc9 -lut 4; check; select -assert-count 2 t:$lut; select -assert-none c:* t:$lut %n %i' abc9.v diff --git a/tests/techmap/abc9/run-test.sh b/tests/techmap/abc9/run-test.sh new file mode 100755 index 000000000..e2fc11e52 --- /dev/null +++ b/tests/techmap/abc9/run-test.sh @@ -0,0 +1,10 @@ +#!/bin/bash +set -e +for x in *_runtest.sh; do + echo "Running $x.." + if ! bash $x &> ${x%.sh}.log; then + tail ${x%.sh}.log + echo ERROR + exit 1 + fi +done diff --git a/tests/techmap/run-test.sh b/tests/techmap/run-test.sh index e2fc11e52..129451e08 100755 --- a/tests/techmap/run-test.sh +++ b/tests/techmap/run-test.sh @@ -8,3 +8,11 @@ for x in *_runtest.sh; do exit 1 fi done + +for d in */; do + if [ -x $d/run-test.sh ]; then + cd $d + bash run-test.sh + cd .. + fi +done |