Skip to content

Commit baf136e

Browse files
committed
ram: give error if multiple primary power/ground pin names detected across cells, remove unnecessary clear function for pin sets
Signed-off-by: Thinh Nguyen <nguyenthinh19011@gmail.com>
1 parent 1ee8a78 commit baf136e

1 file changed

Lines changed: 14 additions & 2 deletions

File tree

src/ram/src/ram.cpp

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -590,6 +590,20 @@ std::map<PortRole, std::string> RamGen::buildPortMap(dbMaster* master)
590590
}
591591
}
592592

593+
if (power_pin_names_.size() > 1) {
594+
logger_->error(RAM,
595+
42,
596+
"Multiple primary power pin names detected across cells: {}",
597+
fmt::join(power_pin_names_, ", "));
598+
}
599+
if (ground_pin_names_.size() > 1) {
600+
logger_->error(
601+
RAM,
602+
43,
603+
"Multiple primary ground pin names detected across cells: {}",
604+
fmt::join(ground_pin_names_, ", "));
605+
}
606+
593607
return pin_map;
594608
}
595609

@@ -928,8 +942,6 @@ void RamGen::ramPdngen(const char* power_net_name,
928942
}
929943

930944
block_->globalConnect(false, false);
931-
power_pin_names_.clear();
932-
ground_pin_names_.clear();
933945

934946
std::string grid_name = "ram_grid";
935947
pdngen_->setCoreDomain(power_net, nullptr, ground_net, {});

0 commit comments

Comments
 (0)