mirror of
https://github.com/YosysHQ/yosys
synced 2025-06-06 14:13:23 +00:00
Added module->ports
This commit is contained in:
parent
746aac540b
commit
1bf7a18fec
9 changed files with 23 additions and 10 deletions
|
@ -726,14 +726,14 @@ struct ExtractPass : public Pass {
|
|||
newMod->name = stringf("\\needle%05d_%s_%dx", needleCounter++, id2cstr(haystack_map.at(result.graphId)->name), result.totalMatchesAfterLimits);
|
||||
map->add(newMod);
|
||||
|
||||
int portCounter = 1;
|
||||
for (auto wire : wires) {
|
||||
RTLIL::Wire *newWire = newMod->addWire(wire->name, wire->width);
|
||||
newWire->port_id = portCounter++;
|
||||
newWire->port_input = true;
|
||||
newWire->port_output = true;
|
||||
}
|
||||
|
||||
newMod->fixup_ports();
|
||||
|
||||
for (auto cell : cells) {
|
||||
RTLIL::Cell *newCell = newMod->addCell(cell->name, cell->type);
|
||||
newCell->parameters = cell->parameters;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue