File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1461,6 +1461,43 @@ int64_t NesterovBaseCommon::getHpwl()
14611461 return hpwl;
14621462}
14631463
1464+ void NesterovBaseCommon::resetMinRcCellSize ()
1465+ {
1466+ minRcCellSize_.clear ();
1467+ minRcCellSize_.shrink_to_fit ();
1468+ }
1469+
1470+ void NesterovBaseCommon::resizeMinRcCellSize ()
1471+ {
1472+ minRcCellSize_.resize (nbc_gcells_.size (), std::make_pair (0 , 0 ));
1473+ }
1474+
1475+ void NesterovBaseCommon::updateMinRcCellSize ()
1476+ {
1477+ for (auto & gCell : nbc_gcells_) {
1478+ if (!gCell ->isStdInstance ()) {
1479+ continue ;
1480+ }
1481+
1482+ minRcCellSize_[&gCell - nbc_gcells_.data ()]
1483+ = std::make_pair (gCell ->dx (), gCell ->dy ());
1484+ }
1485+ }
1486+
1487+ void NesterovBaseCommon::revertGCellSizeToMinRc ()
1488+ {
1489+ // revert back the gcell sizes
1490+ for (auto & gCell : nbc_gcells_) {
1491+ if (!gCell ->isStdInstance ()) {
1492+ continue ;
1493+ }
1494+
1495+ int idx = &gCell - nbc_gcells_.data ();
1496+
1497+ gCell ->setSize (minRcCellSize_[idx].first , minRcCellSize_[idx].second );
1498+ }
1499+ }
1500+
14641501GCell* NesterovBaseCommon::getGCellByIndex (size_t i)
14651502{
14661503 if (i >= gCellStor_ .size ()) {
Original file line number Diff line number Diff line change @@ -838,41 +838,10 @@ class NesterovBaseCommon
838838 void moveGCell (odb::dbInst* db_inst);
839839 void fixPointers ();
840840
841- void resetMinRcCellSize ()
842- {
843- minRcCellSize_.clear ();
844- minRcCellSize_.shrink_to_fit ();
845- }
846-
847- void resizeMinRcCellSize ()
848- {
849- minRcCellSize_.resize (nbc_gcells_.size (), std::make_pair (0 , 0 ));
850- }
851- void updateMinRcCellSize ()
852- {
853- for (auto & gCell : nbc_gcells_) {
854- if (!gCell ->isStdInstance ()) {
855- continue ;
856- }
857-
858- minRcCellSize_[&gCell - nbc_gcells_.data ()]
859- = std::make_pair (gCell ->dx (), gCell ->dy ());
860- }
861- }
862-
863- void revertGCellSizeToMinRc ()
864- {
865- // revert back the gcell sizes
866- for (auto & gCell : nbc_gcells_) {
867- if (!gCell ->isStdInstance ()) {
868- continue ;
869- }
870-
871- int idx = &gCell - nbc_gcells_.data ();
872-
873- gCell ->setSize (minRcCellSize_[idx].first , minRcCellSize_[idx].second );
874- }
875- }
841+ void resetMinRcCellSize ();
842+ void resizeMinRcCellSize ();
843+ void updateMinRcCellSize ();
844+ void revertGCellSizeToMinRc ();
876845
877846 GCell& getGCell (size_t index) { return gCellStor_ [index]; }
878847
You can’t perform that action at this time.
0 commit comments