X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/ddb99d3d0cd5f1792d92ddb345f564e54777c1d1..d18bab6bdd1ec8b733e9ad31aaba20ebec4dbd96:/src/surf/surf_routing.c diff --git a/src/surf/surf_routing.c b/src/surf/surf_routing.c index 53a519b376..ae8e115f5a 100644 --- a/src/surf/surf_routing.c +++ b/src/surf/surf_routing.c @@ -746,9 +746,6 @@ static void routing_parse_cabinet(sg_platf_cabinet_cbarg_t cabinet) s_sg_platf_host_cbarg_t host; memset(&host, 0, sizeof(host)); host.initial_state = SURF_RESOURCE_ON; - xbt_dynar_t power_state_list = xbt_dynar_new(sizeof(double), NULL); - xbt_dynar_push(power_state_list,&cabinet->power); - host.power_peak = power_state_list; host.pstate = 0; host.power_scale = 1.0; host.core_amount = 1; @@ -768,6 +765,9 @@ static void routing_parse_cabinet(sg_platf_cabinet_cbarg_t cabinet) link_id = bprintf("link_%s%d%s",cabinet->prefix,i,cabinet->suffix); host.id = host_id; link.id = link_id; + xbt_dynar_t power_state_list = xbt_dynar_new(sizeof(double), NULL); + xbt_dynar_push(power_state_list,&cabinet->power); + host.power_peak = power_state_list; sg_platf_new_host(&host); sg_platf_new_link(&link);