Index: plugins/rt_topo/crbs_route.c =================================================================== --- plugins/rt_topo/crbs_route.c (revision 1408) +++ plugins/rt_topo/crbs_route.c (revision 1409) @@ -54,7 +54,7 @@ dist = crbs_dist_heur(crbs->target->pt->x, crbs->target->pt->y, tx, ty); /* prefer concave over convex assuming the puller will get it shorter */ - if ((from->type & 0x0F) == ADDR_ARC_CONCAVE) + if (((from->type & 0x0F) == ADDR_ARC_VCONCAVE) || ((from->type & 0x0F) == ADDR_ARC_CONCAVE)) dist = dist * 2 / 3; return dist; @@ -69,6 +69,7 @@ int from_dir = 0, to_dir = 0; switch(from->type & 0x0F) { + case ADDR_ARC_VCONCAVE: case ADDR_ARC_CONCAVE: tune = 2.0/3.0; /* prefer concave over convex assuming the puller will get it shorter */ case ADDR_ARC_CONVEX: @@ -86,6 +87,7 @@ } switch(to->type & 0x0F) { + case ADDR_ARC_VCONCAVE: case ADDR_ARC_CONCAVE: tune = tune * (2.0/3.0); case ADDR_ARC_CONVEX: @@ -291,6 +293,7 @@ switch(curr->type & 0x0F) { case ADDR_ARC_CONVEX: from_type = (curr->new_adir > 0) ? "convex cw" : "convex ccw"; break; case ADDR_ARC_CONCAVE: from_type = (curr->new_adir > 0) ? "concave cw" : "concave ccw"; break; + case ADDR_ARC_VCONCAVE: from_type = "vconcave"; break; case ADDR_POINT: from_type = "incident"; break; default: from_type = "UNKNOWN"; break; } @@ -311,7 +314,7 @@ } - while(a->grbs_idx < 4) { + while(a->grbs_idx < 5) { if (crbs_trace_ast) printf(" try from %s P%ld to P%ld", from_type, curr->pt->uid, pt->gpt->uid); if (crbs->disable_concave) { @@ -324,8 +327,9 @@ switch(a->grbs_idx) { case 0: if (crbs_trace_ast) printf(" concave ccw"); next = crbs_next_hop(crbs, curr, pt, GRBS_ADIR_CONCAVE_CCW); break; case 1: if (crbs_trace_ast) printf(" concave cw"); next = crbs_next_hop(crbs, curr, pt, GRBS_ADIR_CONCAVE_CW); break; - case 2: if (crbs_trace_ast) printf(" convex ccw"); next = crbs_next_hop(crbs, curr, pt, GRBS_ADIR_CONVEX_CCW); break; - case 3: if (crbs_trace_ast) printf(" convex cw"); next = crbs_next_hop(crbs, curr, pt, GRBS_ADIR_CONVEX_CW); break; + case 2: if (crbs_trace_ast) printf(" vconcave"); next = crbs_next_hop(crbs, curr, pt, GRBS_ADIR_VCONCAVE); break; + case 3: if (crbs_trace_ast) printf(" convex ccw"); next = crbs_next_hop(crbs, curr, pt, GRBS_ADIR_CONVEX_CCW); break; + case 4: if (crbs_trace_ast) printf(" convex cw"); next = crbs_next_hop(crbs, curr, pt, GRBS_ADIR_CONVEX_CW); break; } a->grbs_idx++; @@ -499,6 +503,7 @@ case GRBS_ADIR_CONVEX_CW: printf(" cw P%ld", da->pt->uid); break; case GRBS_ADIR_CONCAVE_CCW: printf(" concave ccw P%ld", da->pt->uid); break; case GRBS_ADIR_CONCAVE_CW: printf(" concave cw P%ld", da->pt->uid); break; + case GRBS_ADIR_VCONCAVE: printf(" vconcave P%ld", da->pt->uid); break; } na = grbs_path_next(&crbs->grbs, crbs->routing_tn, pa, da->pt, da->user_long); if (na != NULL) { @@ -529,11 +534,13 @@ } for(na = firsta; na != NULL; na = na->user_data) { - grbs_arc_t *arc = grbs_path_realize(&crbs->grbs, crbs->routing_tn, na, 0); - if (arc != NULL) - arc->user_data = ctn; - else - abort(); /* we have validated the path so this can not fail */ + if ((na->type & 0x0F) != ADDR_ARC_VCONCAVE) { + grbs_arc_t *arc = grbs_path_realize(&crbs->grbs, crbs->routing_tn, na, 0); + if (arc != NULL) + arc->user_data = ctn; + else + abort(); /* we have validated the path so this can not fail */ + } } {