Commit 515d4fdb authored by Neil McGlohon's avatar Neil McGlohon

Update minimal to only use random for global conns

parent 96ced58e
...@@ -2987,16 +2987,14 @@ static Connection do_dfp_routing(router_state *s, ...@@ -2987,16 +2987,14 @@ static Connection do_dfp_routing(router_state *s,
if (poss_next_stops.size() < 1) if (poss_next_stops.size() < 1)
tw_error(TW_LOC, "MINIMAL DEAD END\n"); tw_error(TW_LOC, "MINIMAL DEAD END\n");
int rand_sel = tw_rand_integer(lp->rng, 0, poss_next_stops.size() -1); ConnectionType conn_type = poss_next_stops[0].conn_type;
return poss_next_stops[rand_sel]; Connection best_min_conn;
if (conn_type == CONN_GLOBAL)
// ConnectionType conn_type = poss_next_stops[0].conn_type; int rand_sel = tw_rand_integer(lp->rng, 0, poss_next_stops.size() -1);
// Connection best_min_conn; return poss_next_stops[rand_sel];
// if (conn_type == CONN_GLOBAL) else
// best_min_conn = get_best_connection_from_conns(s, bf, msg, lp, poss_next_stops); //does the pick 2 and compare best_min_conn = get_absolute_best_connection_from_conns(s, bf, msg, lp, poss_next_stops); //gets absolute best
// else return best_min_conn;
// best_min_conn = get_absolute_best_connection_from_conns(s, bf, msg, lp, poss_next_stops); //gets absolute best
// return best_min_conn;
} }
else { //routing algorithm is specified in routing else { //routing algorithm is specified in routing
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment