write_timing_model area

Signed-off-by: James Cherry <cherry@parallaxsw.com>
This commit is contained in:
James Cherry 2024-03-01 09:23:23 -07:00
parent 1d16e23052
commit b39dd24339
2 changed files with 16 additions and 0 deletions

View File

@ -157,6 +157,21 @@ MakeTimingModel::makeCell()
{
cell_ = lib_builder_->makeCell(library_, cell_name_, filename_);
cell_->setIsMacro(true);
cell_->setArea(findArea());
}
float
MakeTimingModel::findArea()
{
float area = 0.0;
LeafInstanceIterator *leaf_iter = network_->leafInstanceIterator();
while (leaf_iter->hasNext()) {
const Instance *inst = leaf_iter->next();
const LibertyCell *cell = network_->libertyCell(inst);
area += cell->area();
}
delete leaf_iter;
return area;
}
void

View File

@ -57,6 +57,7 @@ public:
private:
void makeLibrary();
void makeCell();
float findArea();
void makePorts();
void checkClock(Clock *clk);
void findTimingFromInputs();