proc_rom: Set `src` on the emitted memory

This commit is contained in:
Martin Povišer 2024-07-25 11:35:39 +02:00 committed by Catherine
parent 118b2829db
commit 7ee685a0b0
1 changed files with 6 additions and 0 deletions

View File

@ -183,6 +183,12 @@ struct RomWorker
mem.rd_ports.push_back(std::move(rd));
mem.emit();
if (sw->has_attribute(ID::src)) {
mem.inits[0].cell->attributes[ID::src] = sw->attributes[ID::src];
mem.rd_ports[0].cell->attributes[ID::src] = sw->attributes[ID::src];
}
for (auto cs: sw->cases)
delete cs;
sw->cases.clear();