mirror of
https://github.com/YosysHQ/yosys
synced 2026-05-25 11:26:22 +00:00
patch: unique heap
This commit is contained in:
parent
dbc7e33908
commit
b7ea32dbee
3 changed files with 15 additions and 12 deletions
|
|
@ -13,13 +13,13 @@ struct TestPatchPass : public Pass {
|
|||
void execute(std::vector<std::string> args, RTLIL::Design *design) override
|
||||
{
|
||||
(void) args;
|
||||
RTLIL::Patch patcher;
|
||||
design->bufNormalize();
|
||||
for (auto module : design->selected_modules()) {
|
||||
patcher.mod = module;
|
||||
patcher.map = SigMap(module);
|
||||
for (auto cell : module->selected_cells()) {
|
||||
if (cell->type == ID($add)) {
|
||||
RTLIL::Patch patcher;
|
||||
patcher.mod = module;
|
||||
patcher.map = SigMap(module);
|
||||
RTLIL::Cell* sub = patcher.addCell(NEW_ID, ID($sub));
|
||||
sub->connections_ = cell->connections();
|
||||
sub->parameters = cell->parameters;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue