Skip to content

Commit 14680bd

Browse files
committed
remove unused vars
1 parent 6acee2b commit 14680bd

File tree

2 files changed

+72
-99
lines changed

2 files changed

+72
-99
lines changed

libs/libarchfpga/src/read_xml_arch_file.cpp

Lines changed: 72 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -5450,7 +5450,7 @@ static void ProcessVib(pugi::xml_node Vib_node, std::vector<t_physical_tile_type
54505450
arch->vib_infs.push_back(vib);
54515451
}
54525452

5453-
static void ProcessFirstStage(pugi::xml_node Stage_node, std::vector<t_physical_tile_type>& PhysicalTileTypes, std::vector<t_first_stage_mux_inf>& first_stages, const pugiutil::loc_data& loc_data) {
5453+
static void ProcessFirstStage(pugi::xml_node Stage_node, std::vector<t_physical_tile_type>& /* PhysicalTileTypes */, std::vector<t_first_stage_mux_inf>& first_stages, const pugiutil::loc_data& loc_data) {
54545454
pugi::xml_node Node;
54555455
pugi::xml_node SubElem;
54565456
//pugi::xml_node Cur;
@@ -5479,7 +5479,7 @@ static void ProcessFirstStage(pugi::xml_node Stage_node, std::vector<t_physical_
54795479
}
54805480
}
54815481

5482-
static void ProcessSecondStage(pugi::xml_node Stage_node, std::vector<t_physical_tile_type>& PhysicalTileTypes, std::vector<t_second_stage_mux_inf>& second_stages, const pugiutil::loc_data& loc_data) {
5482+
static void ProcessSecondStage(pugi::xml_node Stage_node, std::vector<t_physical_tile_type>& /* PhysicalTileTypes */, std::vector<t_second_stage_mux_inf>& second_stages, const pugiutil::loc_data& loc_data) {
54835483
pugi::xml_node Node;
54845484
pugi::xml_node SubElem;
54855485
//pugi::xml_node Cur;
@@ -5665,81 +5665,81 @@ static void ProcessSecondStage(pugi::xml_node Stage_node, std::vector<t_physical
56655665
// }
56665666
// }
56675667

5668-
void parse_pin_name(char* src_string, int* start_pin_index, int* end_pin_index, char* pb_type_name, char* port_name) {
5669-
/* Parses out the pb_type_name and port_name *
5670-
* If the start_pin_index and end_pin_index is specified, parse them too. *
5671-
* Return the values parsed by reference. */
5668+
// void parse_pin_name(char* src_string, int* start_pin_index, int* end_pin_index, char* pb_type_name, char* port_name) {
5669+
// /* Parses out the pb_type_name and port_name *
5670+
// * If the start_pin_index and end_pin_index is specified, parse them too. *
5671+
// * Return the values parsed by reference. */
56725672

5673-
char* source_string = nullptr;
5674-
char* find_format = nullptr;
5675-
int ichar, match_count;
5673+
// char* source_string = nullptr;
5674+
// char* find_format = nullptr;
5675+
// int ichar, match_count;
56765676

5677-
// parse out the pb_type and port name, possibly pin_indices
5678-
find_format = strstr(src_string, "[");
5679-
if (find_format == nullptr) {
5680-
/* Format "pb_type_name.port_name" */
5681-
*start_pin_index = *end_pin_index = -1;
5677+
// // parse out the pb_type and port name, possibly pin_indices
5678+
// find_format = strstr(src_string, "[");
5679+
// if (find_format == nullptr) {
5680+
// /* Format "pb_type_name.port_name" */
5681+
// *start_pin_index = *end_pin_index = -1;
56825682

5683-
strcpy(source_string, src_string);
5683+
// strcpy(source_string, src_string);
56845684

5685-
for (ichar = 0; ichar < (int)(strlen(source_string)); ichar++) {
5686-
if (source_string[ichar] == '.')
5687-
source_string[ichar] = ' ';
5688-
}
5685+
// for (ichar = 0; ichar < (int)(strlen(source_string)); ichar++) {
5686+
// if (source_string[ichar] == '.')
5687+
// source_string[ichar] = ' ';
5688+
// }
56895689

5690-
match_count = sscanf(source_string, "%s %s", pb_type_name, port_name);
5691-
if (match_count != 2) {
5692-
VTR_LOG_ERROR(
5693-
"Invalid pin - %s, name should be in the format "
5694-
"\"pb_type_name\".\"port_name\" or \"pb_type_name\".\"port_name[end_pin_index:start_pin_index]\". "
5695-
"The end_pin_index and start_pin_index can be the same.\n",
5696-
src_string);
5697-
exit(1);
5698-
}
5699-
} else {
5700-
/* Format "pb_type_name.port_name[end_pin_index:start_pin_index]" */
5701-
strcpy(source_string, src_string);
5702-
for (ichar = 0; ichar < (int)(strlen(source_string)); ichar++) {
5703-
//Need white space between the components when using %s with
5704-
//sscanf
5705-
if (source_string[ichar] == '.')
5706-
source_string[ichar] = ' ';
5707-
if (source_string[ichar] == '[')
5708-
source_string[ichar] = ' ';
5709-
}
5710-
5711-
match_count = sscanf(source_string, "%s %s %d:%d]",
5712-
pb_type_name, port_name,
5713-
end_pin_index, start_pin_index);
5714-
if (match_count != 4) {
5715-
match_count = sscanf(source_string, "%s %s %d]",
5716-
pb_type_name, port_name,
5717-
end_pin_index);
5718-
*start_pin_index = *end_pin_index;
5719-
if (match_count != 3) {
5720-
VTR_LOG_ERROR(
5721-
"Invalid pin - %s, name should be in the format "
5722-
"\"pb_type_name\".\"port_name\" or \"pb_type_name\".\"port_name[end_pin_index:start_pin_index]\". "
5723-
"The end_pin_index and start_pin_index can be the same.\n",
5724-
src_string);
5725-
exit(1);
5726-
}
5727-
}
5728-
if (*end_pin_index < 0 || *start_pin_index < 0) {
5729-
VTR_LOG_ERROR(
5730-
"Invalid pin - %s, the pin_index in "
5731-
"[end_pin_index:start_pin_index] should not be a negative value.\n",
5732-
src_string);
5733-
exit(1);
5734-
}
5735-
if (*end_pin_index < *start_pin_index) {
5736-
int temp;
5737-
temp = *end_pin_index;
5738-
*end_pin_index = *start_pin_index;
5739-
*start_pin_index = temp;
5740-
}
5741-
}
5742-
}
5690+
// match_count = sscanf(source_string, "%s %s", pb_type_name, port_name);
5691+
// if (match_count != 2) {
5692+
// VTR_LOG_ERROR(
5693+
// "Invalid pin - %s, name should be in the format "
5694+
// "\"pb_type_name\".\"port_name\" or \"pb_type_name\".\"port_name[end_pin_index:start_pin_index]\". "
5695+
// "The end_pin_index and start_pin_index can be the same.\n",
5696+
// src_string);
5697+
// exit(1);
5698+
// }
5699+
// } else {
5700+
// /* Format "pb_type_name.port_name[end_pin_index:start_pin_index]" */
5701+
// strcpy(source_string, src_string);
5702+
// for (ichar = 0; ichar < (int)(strlen(source_string)); ichar++) {
5703+
// //Need white space between the components when using %s with
5704+
// //sscanf
5705+
// if (source_string[ichar] == '.')
5706+
// source_string[ichar] = ' ';
5707+
// if (source_string[ichar] == '[')
5708+
// source_string[ichar] = ' ';
5709+
// }
5710+
5711+
// match_count = sscanf(source_string, "%s %s %d:%d]",
5712+
// pb_type_name, port_name,
5713+
// end_pin_index, start_pin_index);
5714+
// if (match_count != 4) {
5715+
// match_count = sscanf(source_string, "%s %s %d]",
5716+
// pb_type_name, port_name,
5717+
// end_pin_index);
5718+
// *start_pin_index = *end_pin_index;
5719+
// if (match_count != 3) {
5720+
// VTR_LOG_ERROR(
5721+
// "Invalid pin - %s, name should be in the format "
5722+
// "\"pb_type_name\".\"port_name\" or \"pb_type_name\".\"port_name[end_pin_index:start_pin_index]\". "
5723+
// "The end_pin_index and start_pin_index can be the same.\n",
5724+
// src_string);
5725+
// exit(1);
5726+
// }
5727+
// }
5728+
// if (*end_pin_index < 0 || *start_pin_index < 0) {
5729+
// VTR_LOG_ERROR(
5730+
// "Invalid pin - %s, the pin_index in "
5731+
// "[end_pin_index:start_pin_index] should not be a negative value.\n",
5732+
// src_string);
5733+
// exit(1);
5734+
// }
5735+
// if (*end_pin_index < *start_pin_index) {
5736+
// int temp;
5737+
// temp = *end_pin_index;
5738+
// *end_pin_index = *start_pin_index;
5739+
// *start_pin_index = temp;
5740+
// }
5741+
// }
5742+
// }
57435743

57445744
/* Process vib layout */
57455745
static void ProcessVibLayout(pugi::xml_node vib_layout_tag, t_arch* arch, const pugiutil::loc_data& loc_data) {

vpr/src/route/router_lookahead_map_utils.cpp

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -420,13 +420,6 @@ t_src_opin_delays compute_router_src_opin_lookahead(bool is_flat) {
420420
const std::vector<RRNodeId>& rr_nodes_at_loc = device_ctx.rr_graph.node_lookup().find_grid_nodes_at_all_sides(sample_loc.layer_num, sample_loc.x, sample_loc.y, rr_type);
421421
for (RRNodeId node_id : rr_nodes_at_loc) {
422422
int ptc = rr_graph.node_ptc_num(node_id);
423-
const VibInf* vib;
424-
if (!device_ctx.arch->vib_infs.empty()) {
425-
vib = device_ctx.vib_grid.get_vib(sample_loc.layer_num, sample_loc.x, sample_loc.y);
426-
} else {
427-
vib = nullptr;
428-
}
429-
//const t_vib_inf* vib = device_ctx.vib_grid[sample_loc.layer_num][sample_loc.x][sample_loc.y];
430423
// For the time being, we decide to not let the lookahead explore the node inside the clusters
431424
if (!is_inter_cluster_node(rr_graph, node_id)) {
432425
continue;
@@ -1029,16 +1022,6 @@ static void dijkstra_flood_to_wires(int itile,
10291022

10301023
RRNodeId next_node = rr_graph.rr_nodes().edge_sink_node(edge);
10311024
// For the time being, we decide to not let the lookahead explore the node inside the clusters
1032-
t_physical_tile_type_ptr physical_type = device_ctx.grid.get_physical_type({rr_graph.node_xlow(next_node),
1033-
rr_graph.node_ylow(next_node),
1034-
rr_graph.node_layer(next_node)});
1035-
const VibInf* vib;
1036-
if (!device_ctx.arch->vib_infs.empty()) {
1037-
vib = device_ctx.vib_grid.get_vib(rr_graph.node_layer(next_node), rr_graph.node_xlow(next_node), rr_graph.node_ylow(next_node));
1038-
} else {
1039-
vib = nullptr;
1040-
}
1041-
//const t_vib_inf* vib = device_ctx.vib_grid[rr_graph.node_layer(next_node)][rr_graph.node_xlow(next_node)][rr_graph.node_ylow(next_node)];
10421025
if (!is_inter_cluster_node(rr_graph, next_node)) {
10431026
// Don't go inside the clusters
10441027
continue;
@@ -1394,16 +1377,6 @@ static void expand_dijkstra_neighbours(util::PQ_Entry parent_entry,
13941377
for (t_edge_size edge : rr_graph.edges(parent)) {
13951378
RRNodeId child_node = rr_graph.edge_sink_node(parent, edge);
13961379
// For the time being, we decide to not let the lookahead explore the node inside the clusters
1397-
t_physical_tile_type_ptr physical_type = device_ctx.grid.get_physical_type({rr_graph.node_xlow(child_node),
1398-
rr_graph.node_ylow(child_node),
1399-
rr_graph.node_layer(child_node)});
1400-
const VibInf* vib;
1401-
if (!device_ctx.arch->vib_infs.empty()) {
1402-
vib = device_ctx.vib_grid.get_vib(rr_graph.node_layer(child_node), rr_graph.node_xlow(child_node), rr_graph.node_ylow(child_node));
1403-
} else {
1404-
vib = nullptr;
1405-
}
1406-
14071380
if (!is_inter_cluster_node(rr_graph, child_node)) {
14081381
continue;
14091382
}

0 commit comments

Comments
 (0)