Skip to content

Commit 9790180

Browse files
committed
[vpr][util] fix comment in get_pin_rr_node_id
1 parent 39ee73a commit 9790180

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

vpr/src/util/vpr_utils.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1679,6 +1679,9 @@ RRNodeId get_pin_rr_node_id(const RRSpatialLookup& rr_spatial_lookup,
16791679
std::tie(x_offset, y_offset, pin_sides) = get_pin_coordinates(physical_tile, pin_physical_num, std::vector<e_side>(TOTAL_2D_SIDES.begin(), TOTAL_2D_SIDES.end()));
16801680
VTR_ASSERT(!x_offset.empty());
16811681
RRNodeId node_id = RRNodeId::INVALID();
1682+
// Pin sides from get_pin_coordinates are those specified in the architecture. However, when
1683+
// adding pins to the RR Graph, not all sides may be included (depending on the block’s location).
1684+
// Therefore, we iterate over all sides to find a valid node id.
16821685
for (int coord_idx = 0; coord_idx < (int)pin_sides.size(); coord_idx++) {
16831686
node_id = rr_spatial_lookup.find_node(root_loc.layer_num,
16841687
root_loc.x + x_offset[coord_idx],

0 commit comments

Comments
 (0)