Skip to content

Commit 39ee73a

Browse files
committed
[libs][rr-graph] fix comment
1 parent bc26441 commit 39ee73a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

libs/librrgraph/src/base/check_rr_graph.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -515,10 +515,10 @@ void check_rr_node(const RRGraphView& rr_graph,
515515
}
516516
rr_graph_sides = rr_graph.node_sides(rr_node);
517517
std::tie(std::ignore, std::ignore, arch_side_vec) = get_pin_coordinates(type, ptc_num, std::vector<e_side>(TOTAL_2D_SIDES.begin(), TOTAL_2D_SIDES.end()));
518-
// Number of sides in arch_side_vec may be higher than rr_graph sides since there may be duplicates (a pin may have different x/y offset on the same side)
519-
// Because of that, we iterate over arch_side_vec and check if the side is in rr_graph_sides
520-
for (size_t i = 0; i < arch_side_vec.size(); i++) {
521-
if (std::find(rr_graph_sides.begin(), rr_graph_sides.end(), arch_side_vec[i]) == rr_graph_sides.end()) {
518+
// sides in the architecture are a superset of the sides for a pin in RR Graph. We iterate over the sides stored
519+
// in the RR Graph to ensure that all of them also exist in the architecture.
520+
for (size_t i = 0; i < rr_graph_sides.size(); i++) {
521+
if (std::find(arch_side_vec.begin(), arch_side_vec.end(), rr_graph_sides[i]) == arch_side_vec.end()) {
522522
VPR_FATAL_ERROR(VPR_ERROR_ROUTE,
523523
"in check_rr_node: inode %d (type %d) has a different side '%s' in the RR graph and the architecture.\n",
524524
inode,

0 commit comments

Comments
 (0)