Skip to content

Commit 0f35bb8

Browse files
committed
mpl: remove conversion to microns in WL calculations
Signed-off-by: João Mai <[email protected]>
1 parent 6930bc5 commit 0f35bb8

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/mpl/src/SimulatedAnnealingCore.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ float SimulatedAnnealingCore<T>::computeNetsWireLength(
322322
}
323323

324324
template <class T>
325-
double SimulatedAnnealingCore<T>::computeWLForClusterOfUnplacedIOPins(
325+
int64_t SimulatedAnnealingCore<T>::computeWLForClusterOfUnplacedIOPins(
326326
const T& macro,
327327
const T& unplaced_ios,
328328
const float net_weight) const
@@ -331,7 +331,7 @@ double SimulatedAnnealingCore<T>::computeWLForClusterOfUnplacedIOPins(
331331
const int max_dist = die_area_.margin() / 2;
332332

333333
if (isOutsideTheOutline(macro)) {
334-
return net_weight * block_->dbuToMicrons(max_dist);
334+
return net_weight * max_dist;
335335
}
336336

337337
const odb::Point macro_location(macro.getPinX(), macro.getPinY());
@@ -353,7 +353,7 @@ double SimulatedAnnealingCore<T>::computeWLForClusterOfUnplacedIOPins(
353353
= computeDistToNearestRegion(macro_location, {constraint}, nullptr);
354354
}
355355

356-
return net_weight * block_->dbuToMicrons(smallest_distance);
356+
return net_weight * smallest_distance;
357357
}
358358

359359
// We consider the macro outside the outline based on the location of

src/mpl/src/SimulatedAnnealingCore.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ class SimulatedAnnealingCore
119119
void calOutlinePenalty();
120120
void calWirelength();
121121
float computeNetsWireLength(const std::vector<BundledNet>& nets) const;
122-
double computeWLForClusterOfUnplacedIOPins(const T& macro,
122+
int64_t computeWLForClusterOfUnplacedIOPins(const T& macro,
123123
const T& unplaced_ios,
124124
float net_weight) const;
125125
bool isOutsideTheOutline(const T& macro) const;

0 commit comments

Comments
 (0)