3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-09-29 20:59:03 +00:00

Update techlibs to avoid bits()

This commit is contained in:
Robert O'Callahan 2025-08-28 01:55:56 +00:00
parent 360a625785
commit 975bbf2d6d
8 changed files with 22 additions and 26 deletions

View file

@ -36,9 +36,9 @@ void invert_gp_dff(Cell *cell, bool invert_input)
Const initval = cell->getParam(ID::INIT);
if (GetSize(initval) >= 1) {
if (initval[0] == State::S0)
initval.bits()[0] = State::S1;
initval.set(0, State::S1);
else if (initval[0] == State::S1)
initval.bits()[0] = State::S0;
initval.set(0, State::S0);
cell->setParam(ID::INIT, initval);
}
@ -47,9 +47,9 @@ void invert_gp_dff(Cell *cell, bool invert_input)
Const srmode = cell->getParam(ID(SRMODE));
if (GetSize(srmode) >= 1) {
if (srmode[0] == State::S0)
srmode.bits()[0] = State::S1;
srmode.set(0, State::S1);
else if (srmode[0] == State::S1)
srmode.bits()[0] = State::S0;
srmode.set(0, State::S0);
cell->setParam(ID(SRMODE), srmode);
}
}