Skip to content

Commit 73f9a79

Browse files
committed
Updating code.
1 parent 363291f commit 73f9a79

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

vpr/src/place/net_cost_handler.cpp

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,9 @@ enum class NetUpdateState {
5454

5555
const int MAX_FANOUT_CROSSING_COUNT = 50;
5656

57+
double cong_matrix[400][400];
58+
double cong_matrix_new[400][400];
59+
5760
/**
5861
* @brief Crossing counts for nets with different #'s of pins. From
5962
* ICCAD 94 pp. 690 - 695 (with linear interpolation applied by me).
@@ -458,10 +461,6 @@ static double get_net_cost(ClusterNetId net_id, const t_bb& bb);
458461
*/
459462
static double get_net_wirelength_estimate(ClusterNetId net_id, const t_bb& bb);
460463

461-
static void get_cong_matrix(ClusterNetId net_id, const t_bb& bb);
462-
463-
static double get_cong_cost(double chan_width)
464-
465464
/**
466465
* @brief To mitigate round-off errors, every once in a while, the costs of nets are summed up from scratch.
467466
* This functions is called to do that for bb cost. It doesn't calculate the BBs from scratch, it would only add the costs again.
@@ -1846,7 +1845,7 @@ static double get_net_wirelength_estimate(ClusterNetId net_id, const t_bb& bb) {
18461845
return (ncost);
18471846
}
18481847

1849-
static void get_cong_matrix(ClusterNetId net_id, const t_bb& bb) {
1848+
void get_cong_matrix(ClusterNetId net_id, const t_bb& bb) {
18501849
/* Finds the cost due to one net by looking at its coordinate bounding *
18511850
* box. */
18521851
// auto& cluster_ctx = g_vpr_ctx.clustering();
@@ -1865,7 +1864,7 @@ static void get_cong_matrix(ClusterNetId net_id, const t_bb& bb) {
18651864
}
18661865

18671866

1868-
static double get_cong_cost(double chan_width) {
1867+
double get_cong_cost(double chan_width) {
18691868
auto& device_ctx = g_vpr_ctx.device();
18701869
double max = 0.0;
18711870
double avg = 1e-4,var=0.0;

vpr/src/place/net_cost_handler.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,3 +147,7 @@ void init_try_swap_net_cost_structs(size_t num_nets, bool cube_bb);
147147
* @brief Free (layer_)ts_bb_edge_new, (layer_)ts_bb_coord_new, ts_layer_sink_pin_count, and ts_nets_to_update data structures.
148148
*/
149149
void free_try_swap_net_cost_structs();
150+
151+
void get_cong_matrix(ClusterNetId net_id, const t_bb& bb);
152+
153+
double get_cong_cost(double chan_width);

vpr/src/place/place.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,9 +111,6 @@ static int num_swap_accepted = 0;
111111
static int num_swap_aborted = 0;
112112
static int num_ts_called = 0;
113113

114-
double cong_matrix[400][400];
115-
double cong_matrix_new[400][400];
116-
117114
float congestion_tradeoff = 1.0;
118115

119116
std::unique_ptr<FILE, decltype(&vtr::fclose)> f_move_stats_file(nullptr,

0 commit comments

Comments
 (0)