@@ -2063,50 +2063,6 @@ void print_switch_usage() {
2063
2063
delete[] inward_switch_inf;
2064
2064
}
2065
2065
2066
- /*
2067
- * Motivation:
2068
- * to see what portion of long wires are utilized
2069
- * potentially a good measure for router look ahead quality
2070
- */
2071
- /*
2072
- * void print_usage_by_wire_length() {
2073
- * map<int, int> used_wire_count;
2074
- * map<int, int> total_wire_count;
2075
- * auto& device_ctx = g_vpr_ctx.device();
2076
- * for (const RRNodeId& rr_id : device_ctx.rr_graph.nodes()){
2077
- * if (rr_graph.node_type(rr_id) == CHANX || rr_graph.node_type(rr_id) == CHANY) {
2078
- * //int length = abs(rr_graph.node_xhigh(rr_id) + rr_graph.node_yhigh(rr_id)
2079
- * // - rr_graph.node_xlow(rr_id) - rr_graph.node_ylow(rr_id));
2080
- * int length = device_ctx.rr_nodes[(size_t)rr_id].get_length();
2081
- * if (rr_node_route_inf[(size_t)rr_id].occ() > 0) {
2082
- * if (used_wire_count.count(length) == 0)
2083
- * used_wire_count[length] = 0;
2084
- * used_wire_count[length] ++;
2085
- * }
2086
- * if (total_wire_count.count(length) == 0)
2087
- * total_wire_count[length] = 0;
2088
- * total_wire_count[length] ++;
2089
- * }
2090
- * }
2091
- * int total_wires = 0;
2092
- * map<int, int>::iterator itr;
2093
- * for (itr = total_wire_count.begin(); itr != total_wire_count.end(); itr++) {
2094
- * total_wires += itr->second;
2095
- * }
2096
- * VTR_LOG("\n\t-=-=-=-=-=-=-=-=-=-=- wire usage stats -=-=-=-=-=-=-=-=-=-=-\n");
2097
- * for (itr = total_wire_count.begin(); itr != total_wire_count.end(); itr++)
2098
- * VTR_LOG("\ttotal number: wire of length %d, ratio to all length of wires: %g\n", itr->first, ((float)itr->second) / total_wires);
2099
- * for (itr = used_wire_count.begin(); itr != used_wire_count.end(); itr++) {
2100
- * float ratio_to_same_type_total = ((float)itr->second) / total_wire_count[itr->first];
2101
- * float ratio_to_all_type_total = ((float)itr->second) / total_wires;
2102
- * VTR_LOG("\t\tratio to same type of wire: %g\tratio to all types of wire: %g\n", ratio_to_same_type_total, ratio_to_all_type_total);
2103
- * }
2104
- * VTR_LOG("\n\t-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n\n");
2105
- * used_wire_count.clear();
2106
- * total_wire_count.clear();
2107
- * }
2108
- */
2109
-
2110
2066
void place_sync_external_block_connections (ClusterBlockId iblk,
2111
2067
BlkLocRegistry& blk_loc_registry) {
2112
2068
const auto & cluster_ctx = g_vpr_ctx.clustering ();
0 commit comments