diff options
author | Clifford Wolf <clifford@clifford.at> | 2014-08-14 11:22:45 +0200 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2014-08-14 11:22:45 +0200 |
commit | 28cf48e31f049f8343023de46cd916ac47fcfc5d (patch) | |
tree | a9f23f5705ab78e95a5f03cd55430942beae6862 /tests | |
parent | 996c06f64dcb1619584c88d101c5ba258b2b26af (diff) | |
download | yosys-28cf48e31f049f8343023de46cd916ac47fcfc5d.tar.gz yosys-28cf48e31f049f8343023de46cd916ac47fcfc5d.tar.bz2 yosys-28cf48e31f049f8343023de46cd916ac47fcfc5d.zip |
Some improvements in FSM mapping and recoding
Diffstat (limited to 'tests')
-rw-r--r-- | tests/fsm/generate.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/fsm/generate.py b/tests/fsm/generate.py index 66ca2af5e..b5b4626df 100644 --- a/tests/fsm/generate.py +++ b/tests/fsm/generate.py @@ -52,7 +52,8 @@ for idx in range(50): print(' output reg%s [%d:0] y;' % (random.choice(['', ' signed']), random.randint(0, 31))) print(' output reg%s [%d:0] z;' % (random.choice(['', ' signed']), random.randint(0, 31))) state_bits = random.randint(5, 16); - print(' reg [%d:0] state;' % (state_bits-1)) + print(' %sreg [%d:0] state;' % (random.choice(['', '(* fsm_encoding = "one-hot" *)', + '(* fsm_encoding = "binary" *)']), state_bits-1)) states=[] for i in range(random.randint(2, 10)): n = random.randint(0, 2**state_bits-1) |