mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-29 20:05:52 +00:00
Add tests
This commit is contained in:
parent
266511b29e
commit
3f0bb441f8
16 changed files with 109 additions and 8 deletions
5
tests/aig/and.aag
Normal file
5
tests/aig/and.aag
Normal file
|
@ -0,0 +1,5 @@
|
|||
aag 3 2 0 1 1
|
||||
2
|
||||
4
|
||||
6
|
||||
6 2 4
|
3
tests/aig/buffer.aag
Normal file
3
tests/aig/buffer.aag
Normal file
|
@ -0,0 +1,3 @@
|
|||
aag 1 1 0 1 0
|
||||
2
|
||||
2
|
3
tests/aig/cnt1.aag
Normal file
3
tests/aig/cnt1.aag
Normal file
|
@ -0,0 +1,3 @@
|
|||
aag 1 0 1 0 0 1
|
||||
2 3
|
||||
2
|
8
tests/aig/cnt1e.aag
Normal file
8
tests/aig/cnt1e.aag
Normal file
|
@ -0,0 +1,8 @@
|
|||
aag 5 1 1 0 3 1
|
||||
2
|
||||
4 10
|
||||
4
|
||||
6 5 3
|
||||
8 4 2
|
||||
10 9 7
|
||||
b0 AIGER_NEVER
|
1
tests/aig/empty.aag
Normal file
1
tests/aig/empty.aag
Normal file
|
@ -0,0 +1 @@
|
|||
aag 0 0 0 0 0
|
2
tests/aig/false.aag
Normal file
2
tests/aig/false.aag
Normal file
|
@ -0,0 +1,2 @@
|
|||
aag 0 0 0 1 0
|
||||
0
|
14
tests/aig/halfadder.aag
Normal file
14
tests/aig/halfadder.aag
Normal file
|
@ -0,0 +1,14 @@
|
|||
aag 7 2 0 2 3
|
||||
2
|
||||
4
|
||||
6
|
||||
12
|
||||
6 13 15
|
||||
12 2 4
|
||||
14 3 5
|
||||
i0 x
|
||||
i1 y
|
||||
o0 s
|
||||
o1 c
|
||||
c
|
||||
half adder
|
3
tests/aig/inverter.aag
Normal file
3
tests/aig/inverter.aag
Normal file
|
@ -0,0 +1,3 @@
|
|||
aag 1 1 0 1 0
|
||||
2
|
||||
3
|
4
tests/aig/notcnt1.aag
Normal file
4
tests/aig/notcnt1.aag
Normal file
|
@ -0,0 +1,4 @@
|
|||
aag 1 0 1 0 0 1
|
||||
2 3
|
||||
3
|
||||
b0 AIGER_NEVER
|
8
tests/aig/notcnt1e.aag
Normal file
8
tests/aig/notcnt1e.aag
Normal file
|
@ -0,0 +1,8 @@
|
|||
aag 5 1 1 0 3 1
|
||||
2
|
||||
4 10
|
||||
5
|
||||
6 5 3
|
||||
8 4 2
|
||||
10 9 7
|
||||
b0 AIGER_NEVER
|
5
tests/aig/or.aag
Normal file
5
tests/aig/or.aag
Normal file
|
@ -0,0 +1,5 @@
|
|||
aag 3 2 0 1 1
|
||||
2
|
||||
4
|
||||
7
|
||||
6 3 5
|
20
tests/aig/run-test.sh
Executable file
20
tests/aig/run-test.sh
Executable file
|
@ -0,0 +1,20 @@
|
|||
#!/bin/bash
|
||||
|
||||
OPTIND=1
|
||||
seed="" # default to no seed specified
|
||||
while getopts "S:" opt
|
||||
do
|
||||
case "$opt" in
|
||||
S) arg="${OPTARG#"${OPTARG%%[![:space:]]*}"}" # remove leading space
|
||||
seed="SEED=$arg" ;;
|
||||
esac
|
||||
done
|
||||
shift "$((OPTIND-1))"
|
||||
|
||||
# check for Icarus Verilog
|
||||
if ! which iverilog > /dev/null ; then
|
||||
echo "$0: Error: Icarus Verilog 'iverilog' not found."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
exec ${MAKE:-make} -f ../tools/autotest.mk $seed *.aag EXTRA_FLAGS="-f aiger"
|
14
tests/aig/toggle-re.aag
Normal file
14
tests/aig/toggle-re.aag
Normal file
|
@ -0,0 +1,14 @@
|
|||
aag 7 2 1 2 4
|
||||
2
|
||||
4
|
||||
6 8
|
||||
6
|
||||
7
|
||||
8 4 10
|
||||
10 13 15
|
||||
12 2 6
|
||||
14 3 7
|
||||
i0 enable
|
||||
i1 reset
|
||||
o0 Q
|
||||
o1 !Q
|
4
tests/aig/toggle.aag
Normal file
4
tests/aig/toggle.aag
Normal file
|
@ -0,0 +1,4 @@
|
|||
aag 1 0 1 2 0
|
||||
2 3
|
||||
2
|
||||
3
|
2
tests/aig/true.aag
Normal file
2
tests/aig/true.aag
Normal file
|
@ -0,0 +1,2 @@
|
|||
aag 0 0 0 1 0
|
||||
1
|
Loading…
Add table
Add a link
Reference in a new issue