diff options
author | Clifford Wolf <clifford@clifford.at> | 2017-01-26 09:01:26 +0100 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2017-01-26 09:05:59 +0100 |
commit | 49b816048833d25921e45bfb248643acbf23b8de (patch) | |
tree | 666ab11219e95e87d484448c6065b3c73a55d302 /passes | |
parent | b0a430f601647894886360d446bf136aac0a72ca (diff) | |
download | yosys-49b816048833d25921e45bfb248643acbf23b8de.tar.gz yosys-49b816048833d25921e45bfb248643acbf23b8de.tar.bz2 yosys-49b816048833d25921e45bfb248643acbf23b8de.zip |
Add warnings for quickly growing FSM table size in fsm_expand
Diffstat (limited to 'passes')
-rw-r--r-- | passes/fsm/fsm_expand.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/passes/fsm/fsm_expand.cc b/passes/fsm/fsm_expand.cc index e7b9dcf90..0a2166b99 100644 --- a/passes/fsm/fsm_expand.cc +++ b/passes/fsm/fsm_expand.cc @@ -173,6 +173,16 @@ struct FsmExpand new_ctrl_out.append(output_sig); fsm_cell->setPort("\\CTRL_OUT", new_ctrl_out); + if (GetSize(input_sig) > 10) + log_warning("Cell %s.%s (%s) has %d input bits, merging into FSM %s.%s might be problematic.\n", + log_id(cell->module), log_id(cell), log_id(cell->type), + GetSize(input_sig), log_id(fsm_cell->module), log_id(fsm_cell)); + + if (GetSize(fsm_data.transition_table) > 10000) + log_warning("Transition table for FSM %s.%s already has %d rows, merging more cells " + "into this FSM might be problematic.\n", log_id(fsm_cell->module), log_id(fsm_cell), + GetSize(fsm_data.transition_table)); + std::vector<FsmData::transition_t> new_transition_table; for (auto &tr : fsm_data.transition_table) { for (int i = 0; i < (1 << input_sig.size()); i++) { |