mirror of
https://github.com/YosysHQ/yosys
synced 2026-07-26 00:52:35 +00:00
Refactor bmuxmap attribute inheritance
This commit is contained in:
parent
f97587db61
commit
2e030bfdfd
1 changed files with 2 additions and 6 deletions
|
|
@ -97,9 +97,7 @@ struct BmuxmapPass : public Pass {
|
||||||
IdString cell_name = cell->name; // SILIMATE: Save the original cell name
|
IdString cell_name = cell->name; // SILIMATE: Save the original cell name
|
||||||
module->rename(cell_name, NEW_ID); // SILIMATE: Rename the original cell, which will be deleted
|
module->rename(cell_name, NEW_ID); // SILIMATE: Rename the original cell, which will be deleted
|
||||||
RTLIL::Cell *pmux = module->addPmux(cell_name, new_a, data, new_s, new_data); // SILIMATE: Improve the naming
|
RTLIL::Cell *pmux = module->addPmux(cell_name, new_a, data, new_s, new_data); // SILIMATE: Improve the naming
|
||||||
for (auto attr : cell->attributes) // SILIMATE: Copy all attributes from original cell to new cell
|
pmux->attributes = cell->attributes; // SILIMATE: Copy all attributes from original cell to new cell
|
||||||
pmux->attributes[attr.first] = attr.second;
|
|
||||||
pmux->set_bool_attribute("\\bmuxmap"); // SILIMATE: Mark the cell as created by bmuxmap
|
|
||||||
data = new_data;
|
data = new_data;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
@ -112,9 +110,7 @@ struct BmuxmapPass : public Pass {
|
||||||
data.extract(i*2+width, width),
|
data.extract(i*2+width, width),
|
||||||
sel[idx],
|
sel[idx],
|
||||||
new_data.extract(i, width));
|
new_data.extract(i, width));
|
||||||
for (auto attr : cell->attributes) // SILIMATE: Copy all attributes from original cell to new cell
|
mux->attributes = cell->attributes; // SILIMATE: Copy all attributes from original cell to new cell
|
||||||
mux->attributes[attr.first] = attr.second;
|
|
||||||
mux->set_bool_attribute("\\bmuxmap"); // SILIMATE: Mark the cell as created by bmuxmap
|
|
||||||
}
|
}
|
||||||
data = new_data;
|
data = new_data;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue