Skip to content

Commit f67b464

Browse files
committed
grt: use all APs for non-core cells
Signed-off-by: Eder Monteiro <[email protected]>
1 parent 40063b9 commit f67b464

File tree

3 files changed

+24
-1
lines changed

3 files changed

+24
-1
lines changed

src/grt/src/GlobalRouter.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -934,8 +934,12 @@ bool GlobalRouter::findPinAccessPointPositions(
934934
access_points.insert(
935935
access_points.begin(), bpin_pas.begin(), bpin_pas.end());
936936
}
937-
} else {
937+
} else if (pin.isCorePin()) {
938938
access_points = pin.getITerm()->getPrefAccessPoints();
939+
} else {
940+
for (const auto& [pin, aps] : pin.getITerm()->getAccessPoints()) {
941+
access_points.insert(access_points.end(), aps.begin(), aps.end());
942+
}
939943
}
940944

941945
if (access_points.empty()) {

src/grt/src/Pin.cpp

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,4 +185,22 @@ odb::Point Pin::getPositionNearInstEdge(const odb::Rect& pin_box,
185185
return pin_pos;
186186
}
187187

188+
bool Pin::isCorePin() const
189+
{
190+
if (is_port_) {
191+
return false;
192+
}
193+
194+
if (connected_to_pad_or_macro_) {
195+
return false;
196+
}
197+
198+
odb::dbInst* inst = iterm->getInst();
199+
if (inst->getMaster()->isCore()) {
200+
return true;
201+
}
202+
203+
return false;
204+
}
205+
188206
} // namespace grt

src/grt/src/Pin.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ class Pin
6666
bool isDriver();
6767
odb::Point getPositionNearInstEdge(const odb::Rect& pin_box,
6868
const odb::Point& rect_middle) const;
69+
bool isCorePin() const;
6970

7071
private:
7172
void determineEdge(const odb::Rect& bounds,

0 commit comments

Comments
 (0)