static void parse_S_AS_XML(void)
{
parse_S_AS(A_surfxml_AS_id, A_surfxml_AS_routing);
-
- if (strcmp(A_surfxml_AS_coordinates,"")) {
- if(!COORD_ASR_LEVEL) xbt_die("To use coordinates, you must set configuration 'coordinates' to 'yes'");
- xbt_dynar_t ctn = xbt_str_split_str(A_surfxml_AS_coordinates, " ");
- xbt_dynar_shrink(ctn, 0);
- xbt_lib_set(as_router_lib,A_surfxml_AS_id,COORD_ASR_LEVEL,(void *) ctn);
- }
}
/*
{
surfxml_add_callback(STag_surfxml_config_cb_list, &routing_parse_Sconfig);
surfxml_add_callback(ETag_surfxml_config_cb_list, &routing_parse_Econfig);
- surfxml_add_callback(STag_surfxml_prop_cb_list, &parse_properties);
+ surfxml_add_callback(STag_surfxml_prop_cb_list, &parse_properties_XML);
surfxml_add_callback(STag_surfxml_AS_cb_list, &surf_parse_models_setup);
surfxml_add_callback(STag_surfxml_random_cb_list, &routing_parse_Srandom);
}
rule_route_t ruleroute = xbt_new0(s_rule_route_t, 1);
const char *error;
int erroffset;
+
+ if(!strcmp(rc->routing->name,"Vivaldi")){
+ if(xbt_dynar_length(route->generic_route.link_list) != 0)
+ xbt_die("You can't have link_ctn with Model Vivaldi.");
+ }
+
ruleroute->re_src = pcre_compile(src, 0, &error, &erroffset, NULL);
xbt_assert(ruleroute->re_src,
"PCRE compilation failed at offset %d (\"%s\"): %s\n",
rule_route_extended_t ruleroute_e = xbt_new0(s_rule_route_extended_t, 1);
const char *error;
int erroffset;
+
+ if(!strcmp(rc->routing->name,"Vivaldi")){
+ if(xbt_dynar_length(route->generic_route.link_list) != 0)
+ xbt_die("You can't have link_ctn with Model Vivaldi.");
+ }
+
ruleroute_e->generic_rule_route.re_src =
pcre_compile(src, 0, &error, &erroffset, NULL);
xbt_assert(ruleroute_e->generic_rule_route.re_src,
xbt_die("The src(%s in %s) and dst(%s in %s) are in differents AS",
src, src_as->name, dst, dst_as->name);
if(rc != dst_as)
- xbt_die("The routing component of src and dst is not the same as the network elements belong (%s==%s)",
- rc->name, dst_as->name);
+ xbt_die("The routing component of src'%s' and dst'%s' is not the same as the network elements belong (%s?=%s?=%s)",
+ src,dst,src_as->name, dst_as->name,rc->name);
}
static void routing_parse_Sconfig(void)
SURFXML_BUFFER_SET(AS_id, cluster_id);
#ifdef HAVE_PCRE_LIB
SURFXML_BUFFER_SET(AS_routing, "RuleBased");
- SURFXML_BUFFER_SET(AS_coordinates, "");
XBT_DEBUG("<AS id=\"%s\"\trouting=\"RuleBased\">", cluster_id);
#else
SURFXML_BUFFER_SET(AS_routing, "Full");
- SURFXML_BUFFER_SET(AS_coordinates, "");
XBT_DEBUG("<AS id=\"%s\"\trouting=\"Full\">", cluster_id);
#endif
SURFXML_START_TAG(AS);
surfxml_bufferstack_push(1);
SURFXML_BUFFER_SET(AS_id, peer_id);
- SURFXML_BUFFER_SET(AS_coordinates, peer_coord);
SURFXML_BUFFER_SET(AS_routing, "Full");
XBT_DEBUG("<AS id=\"%s\"\trouting=\"Full\">", peer_id);