mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-23 17:15:33 +00:00
Respect opt_expr -keepdc as per @cliffordwolf
This commit is contained in:
parent
379f33af54
commit
6f971470f8
2 changed files with 15 additions and 1 deletions
|
@ -748,7 +748,7 @@ void replace_const_cells(RTLIL::Design *design, RTLIL::Module *module, bool cons
|
|||
if (cell->type.in(ID($shiftx), ID($shift))) {
|
||||
SigSpec sig_a = assign_map(cell->getPort(ID::A));
|
||||
int width;
|
||||
bool trim_x = true;
|
||||
bool trim_x = cell->type == ID($shiftx) || !keepdc;
|
||||
bool trim_0 = cell->type == ID($shift);
|
||||
for (width = GetSize(sig_a); width > 1; width--) {
|
||||
if ((trim_x && sig_a[width-1] == State::Sx) ||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue