added license, moved cell libs into repo
added buffer (not tested),
This commit is contained in:
9
test/unit_tests/fifo3_8bit/test.act
Normal file
9
test/unit_tests/fifo3_8bit/test.act
Normal file
@ -0,0 +1,9 @@
|
||||
import template::dataflow_neuro
|
||||
|
||||
defproc fifo3_8bit (avMx1of2<8> A; avMx1of2<8> Y)
|
||||
{
|
||||
avMx1of2<8> _0to1,_1to2;
|
||||
buffer<8> buf0 (.in=A, .out=_0to1);
|
||||
buffer<8> buf1 (.in=_0to1, .out=_1to2);
|
||||
buffer<8> buf2 (.in=_1to2, .out=Y);
|
||||
}
|
40
test/unit_tests/fifo3_8bit/test.prsim
Normal file
40
test/unit_tests/fifo3_8bit/test.prsim
Normal file
@ -0,0 +1,40 @@
|
||||
|
||||
set-channel-neutral "t.A" 8
|
||||
set t.Y.a 0
|
||||
|
||||
cycle
|
||||
system "echo 'reset completed'"
|
||||
status X
|
||||
set Reset 0
|
||||
mode run
|
||||
cycle
|
||||
|
||||
assert t.A.a 0
|
||||
assert-channel-neutral "t.Y" 8
|
||||
|
||||
set-channel-valid "t.A" 8 2
|
||||
|
||||
system "echo 'sending first set A'"
|
||||
cycle
|
||||
assert t.A.a 1
|
||||
set-channel-neutral "t.A" 8
|
||||
cycle
|
||||
assert t.A.a 0
|
||||
|
||||
system "echo 'checking first set'"
|
||||
assert-channel-valid "t.Y" 8 2
|
||||
set t.Y.a 1
|
||||
|
||||
cycle
|
||||
assert-channel-neutral "t.Y" 8
|
||||
set t.Y.a 0
|
||||
|
||||
system "echo 'sending second set'"
|
||||
set-channel-valid "t.A" 8 95
|
||||
cycle
|
||||
assert t.A.a 1
|
||||
set-channel-neutral "t.A" 8
|
||||
cycle
|
||||
system "echo 'checking second set'"
|
||||
assert t.A.a 0
|
||||
assert-channel-valid "t.Y" 8 95
|
Reference in New Issue
Block a user