mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-23 09:05:32 +00:00
Avoid unnecessary copy of a potential large constant value.
The local variable is used just to iterate through the values, so a const reference is all we need.
This commit is contained in:
parent
6e8e4b4550
commit
9d41aa8e28
1 changed files with 2 additions and 2 deletions
|
@ -91,8 +91,8 @@ struct FsmData
|
|||
if (reset_state < 0 || reset_state >= state_num)
|
||||
reset_state = -1;
|
||||
|
||||
RTLIL::Const state_table = cell->parameters[ID::STATE_TABLE];
|
||||
RTLIL::Const trans_table = cell->parameters[ID::TRANS_TABLE];
|
||||
const RTLIL::Const &state_table = cell->parameters[ID::STATE_TABLE];
|
||||
const RTLIL::Const &trans_table = cell->parameters[ID::TRANS_TABLE];
|
||||
|
||||
for (int i = 0; i < state_num; i++) {
|
||||
RTLIL::Const state_code;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue