Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Cople with new gtnets.c and deployment files.
[simgrid.git] / examples / msg / gtnets / gtnets.c
index 4def160..32430c2 100644 (file)
@@ -68,8 +68,6 @@ int master(int argc, char *argv[])
 
   /* time measurement */
   start_time = MSG_get_clock();
-  //MSG_task_put(todo, slave, PORT_22);
-  INFO1("Sending to %s", id_alias);
   MSG_task_send(todo, id_alias);  
 
   end_time = MSG_get_clock();
@@ -97,11 +95,7 @@ int slave(int argc, char *argv[])
   id = atoi(argv[1]);
   sprintf(id_alias, "%d",id);
 
-
-  //a = MSG_task_get(&(task), PORT_22);
-  INFO1("Receiving on %s", id_alias);
-  a = MSG_task_receive(&(task), id_alias );
-  
+  a = MSG_task_receive(&(task), id_alias ); 
 
   if (a != MSG_OK) {
     INFO0("Hey?! What's up?");
@@ -115,10 +109,10 @@ int slave(int argc, char *argv[])
     for(id=0; id<NTASKS; id++){
       if(gl_task_array[id] == NULL){
       }else if(gl_task_array[id] == task){
-       INFO5("===> Estimated Bw of FLOW[%d] : %f ;  message from %s to %s  with remaining : %f", id+1,  gl_data_size[id]/elapsed_time, masternames[id], slavenames[id],  0.0);
+       INFO5("===> Estimated Bw of FLOW[%d] : %f ;  message from %s to %s  with remaining : %f", id,  gl_data_size[id]/elapsed_time, masternames[id], slavenames[id],  0.0);
       }else{
        remaining = MSG_task_get_remaining_communication(gl_task_array[id]);
-       INFO5("===> Estimated Bw of FLOW[%d] : %f ;  message from %s to %s  with remaining : %f", id+1,  (gl_data_size[id]-remaining)/elapsed_time, masternames[id], slavenames[id],  remaining);
+       INFO5("===> Estimated Bw of FLOW[%d] : %f ;  message from %s to %s  with remaining : %f", id,  (gl_data_size[id]-remaining)/elapsed_time, masternames[id], slavenames[id],  remaining);
       }
     }
     exit(0);