@@ -2476,17 +2476,6 @@ static void connect_tile_src_sink_to_pins(RRGraphBuilder& rr_graph_builder,
2476
2476
continue ;
2477
2477
}
2478
2478
auto pin_type = get_pin_type_from_pin_physical_num (physical_type_ptr, pin_num);
2479
- /* int sw_id = -1;
2480
- * if (is_primitive || pin_type == RECEIVER) {
2481
- * VTR_ASSERT(logical_block != nullptr);
2482
- * float primitive_comb_delay = get_pin_primitive_comb_delay(physical_type_ptr,
2483
- * logical_block,
2484
- * pin_num);
2485
- * sw_id = find_create_intra_cluster_sw_arch_idx(arch_sw_inf_map,
2486
- * primitive_comb_delay);
2487
- * } else {
2488
- * sw_id = delayless_switch;
2489
- * }*/
2490
2479
if (class_type == DRIVER) {
2491
2480
VTR_ASSERT (pin_type == DRIVER);
2492
2481
rr_edges_to_create.emplace_back (class_rr_node_id, pin_rr_node_id, delayless_switch, false );
@@ -3009,15 +2998,6 @@ static void add_chain_node_fan_in_edges(RRGraphBuilder& rr_graph_builder,
3009
2998
is_rr_sw_id,
3010
2999
delay);
3011
3000
3012
- /* If the switch found inside the cluster has not seen before and RR graph is not read from a file,
3013
- we need to add this switch to switch_fanin_remap data strcutre which is used later to remap switch IDs
3014
- from architecture ID to RR graph switch ID. The reason why we don't this when RR graph is read from a file
3015
- is that in that case, the switch IDs of edges are alreay RR graph switch IDs. */
3016
- if (is_new_sw && !load_rr_graph) {
3017
- auto & switch_fanin_remap = g_vpr_ctx.mutable_device ().switch_fanin_remap ;
3018
- switch_fanin_remap.push_back ({{UNDEFINED, size_t (sw_id)}});
3019
- }
3020
-
3021
3001
rr_edges_to_create.emplace_back (src_pair.first , sink_rr_node_id, sw_id, is_rr_sw_id);
3022
3002
}
3023
3003
}
@@ -4976,6 +4956,18 @@ static std::pair<bool, int> find_create_intra_cluster_sw(RRGraphBuilder& rr_grap
4976
4956
// If this assumption proven to not be accurate, the implementation needs to be changed.
4977
4957
VTR_ASSERT (arch_sw.fixed_Tdel ());
4978
4958
4959
+ t_rr_switch_inf new_rr_switch_inf = create_rr_switch_from_arch_switch (create_internal_arch_sw (delay),
4960
+ R_minW_nmos,
4961
+ R_minW_pmos);
4962
+ RRSwitchId rr_switch_id = rr_graph.add_rr_switch (new_rr_switch_inf);
4963
+
4964
+ /* If the switch found inside the cluster has not seen before and RR graph is not read from a file,
4965
+ we need to add this switch to switch_fanin_remap data strcutre which is used later to remap switch IDs
4966
+ from architecture ID to RR graph switch ID. The reason why we don't this when RR graph is read from a file
4967
+ is that in that case, the switch IDs of edges are alreay RR graph switch IDs. */
4968
+ auto & switch_fanin_remap = g_vpr_ctx.mutable_device ().switch_fanin_remap ;
4969
+ switch_fanin_remap.push_back ({{UNDEFINED, size_t (rr_switch_id)}});
4970
+
4979
4971
return std::make_pair (true , new_key_num);
4980
4972
} else {
4981
4973
return std::make_pair (false , find_res->first );
0 commit comments