diff options
author | Clifford Wolf <clifford@clifford.at> | 2014-05-12 12:45:47 +0200 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2014-05-12 12:45:47 +0200 |
commit | 68c059565a3b75808e74eb481f14cb7f0c907f37 (patch) | |
tree | c2b57270822033c4dd01cfd559e7dab4b9fbc97e /passes/opt | |
parent | f69b5800c940557cafd20598b03d774dd6cf6f8d (diff) | |
download | yosys-68c059565a3b75808e74eb481f14cb7f0c907f37.tar.gz yosys-68c059565a3b75808e74eb481f14cb7f0c907f37.tar.bz2 yosys-68c059565a3b75808e74eb481f14cb7f0c907f37.zip |
Fixed bug in opt_reduce (see vloghammer issue_044)
Diffstat (limited to 'passes/opt')
-rw-r--r-- | passes/opt/opt_reduce.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/passes/opt/opt_reduce.cc b/passes/opt/opt_reduce.cc index fee8fb71b..dfe214416 100644 --- a/passes/opt/opt_reduce.cc +++ b/passes/opt/opt_reduce.cc @@ -73,7 +73,10 @@ struct OptReduceWorker for (auto child_cell : drivers.find(chunk)) { if (child_cell->type == cell->type) { opt_reduce(cells, drivers, child_cell); - new_sig_a.append(child_cell->connections["\\A"]); + if (child_cell->connections["\\Y"].extract(0, 1) == chunk) + new_sig_a.append(child_cell->connections["\\A"]); + else + new_sig_a.append(RTLIL::State::S0); imported_children = true; } } |