@@ -165,7 +165,7 @@ void check_rr_graph(const RRGraphView& rr_graph,
165
165
inode, rr_node_typename[rr_type], to_node, rr_node_typename[to_rr_type], num_edges_to_node);
166
166
}
167
167
168
- // Between two wire segments
168
+ // Between two wire segments
169
169
VTR_ASSERT_MSG (to_rr_type == e_rr_type::CHANX || to_rr_type == e_rr_type::CHANY || to_rr_type == e_rr_type::IPIN, " Expect channel type or input pin type" );
170
170
VTR_ASSERT_MSG (rr_type == e_rr_type::CHANX || rr_type == e_rr_type::CHANY || rr_type == e_rr_type::OPIN, " Expect channel type or output pin type" );
171
171
@@ -190,7 +190,7 @@ void check_rr_graph(const RRGraphView& rr_graph,
190
190
*/
191
191
if ((to_rr_type == e_rr_type::CHANX || to_rr_type == e_rr_type::CHANY)
192
192
&& (rr_type == e_rr_type::CHANX || rr_type == e_rr_type::CHANY)) {
193
- auto switch_type = rr_graph.rr_switch_inf (RRSwitchId (kv.first )).type ();
193
+ SwitchType switch_type = rr_graph.rr_switch_inf (RRSwitchId (kv.first )).type ();
194
194
195
195
VPR_ERROR (VPR_ERROR_ROUTE, " in check_rr_graph: node %d has %d redundant connections to node %d of switch type %d (%s)" ,
196
196
inode, kv.second , to_node, kv.first , SWITCH_TYPE_STRINGS[size_t (switch_type)]);
@@ -202,14 +202,14 @@ void check_rr_graph(const RRGraphView& rr_graph,
202
202
check_unbuffered_edges (rr_graph, inode);
203
203
204
204
// Check that all config/non-config edges are appropriately organized
205
- for (auto edge : rr_graph.configurable_edges (RRNodeId (inode))) {
205
+ for (t_edge_size edge : rr_graph.configurable_edges (RRNodeId (inode))) {
206
206
if (!rr_graph.edge_is_configurable (RRNodeId (inode), edge)) {
207
207
VPR_FATAL_ERROR (VPR_ERROR_ROUTE, " in check_rr_graph: node %d edge %d is non-configurable, but in configurable edges" ,
208
208
inode, edge);
209
209
}
210
210
}
211
211
212
- for (auto edge : rr_graph.non_configurable_edges (RRNodeId (inode))) {
212
+ for (t_edge_size edge : rr_graph.non_configurable_edges (RRNodeId (inode))) {
213
213
if (rr_graph.edge_is_configurable (RRNodeId (inode), edge)) {
214
214
VPR_FATAL_ERROR (VPR_ERROR_ROUTE, " in check_rr_graph: node %d edge %d is configurable, but in non-configurable edges" ,
215
215
inode, edge);
@@ -528,40 +528,33 @@ void check_rr_node(const RRGraphView& rr_graph,
528
528
static void check_unbuffered_edges (const RRGraphView& rr_graph, int from_node) {
529
529
/* This routine checks that all pass transistors in the routing truly are *
530
530
* bidirectional. It may be a slow check, so don't use it all the time. */
531
-
532
- int from_edge, to_node, to_edge, from_num_edges, to_num_edges;
533
- e_rr_type from_rr_type, to_rr_type;
534
- short from_switch_type;
535
- bool trans_matched;
536
-
537
- from_rr_type = rr_graph.node_type (RRNodeId (from_node));
531
+ e_rr_type from_rr_type = rr_graph.node_type (RRNodeId (from_node));
538
532
if (from_rr_type != e_rr_type::CHANX && from_rr_type != e_rr_type::CHANY)
539
533
return ;
540
534
541
- from_num_edges = rr_graph.num_edges (RRNodeId (from_node));
535
+ int from_num_edges = rr_graph.num_edges (RRNodeId (from_node));
542
536
543
- for (from_edge = 0 ; from_edge < from_num_edges; from_edge++) {
544
- to_node = size_t ( rr_graph.edge_sink_node (RRNodeId (from_node), from_edge) );
545
- to_rr_type = rr_graph.node_type (RRNodeId ( to_node) );
537
+ for (int from_edge = 0 ; from_edge < from_num_edges; from_edge++) {
538
+ RRNodeId to_node = rr_graph.edge_sink_node (RRNodeId (from_node), from_edge);
539
+ e_rr_type to_rr_type = rr_graph.node_type (to_node);
546
540
547
541
if (to_rr_type != e_rr_type::CHANX && to_rr_type != e_rr_type::CHANY)
548
542
continue ;
549
543
550
- from_switch_type = rr_graph.edge_switch (RRNodeId (from_node), from_edge);
544
+ short from_switch_type = rr_graph.edge_switch (RRNodeId (from_node), from_edge);
551
545
552
546
if (rr_graph.rr_switch_inf (RRSwitchId (from_switch_type)).buffered ())
553
547
continue ;
554
548
555
- /* We know that we have a pass transistor from from_node to to_node. Now *
556
- * check that there is a corresponding edge from to_node back to *
557
- * from_node. */
549
+ // We know that we have a pass transistor from from_node to to_node. Now
550
+ // check that there is a corresponding edge from to_node back to from_node.
558
551
559
- to_num_edges = rr_graph.num_edges (RRNodeId ( to_node) );
560
- trans_matched = false ;
552
+ int to_num_edges = rr_graph.num_edges (to_node);
553
+ bool trans_matched = false ;
561
554
562
- for (to_edge = 0 ; to_edge < to_num_edges; to_edge++) {
563
- if (size_t (rr_graph.edge_sink_node (RRNodeId ( to_node) , to_edge)) == size_t (from_node)
564
- && rr_graph.edge_switch (RRNodeId ( to_node) , to_edge) == from_switch_type) {
555
+ for (int to_edge = 0 ; to_edge < to_num_edges; to_edge++) {
556
+ if (size_t (rr_graph.edge_sink_node (to_node, to_edge)) == size_t (from_node)
557
+ && rr_graph.edge_switch (to_node, to_edge) == from_switch_type) {
565
558
trans_matched = true ;
566
559
break ;
567
560
}
0 commit comments