Пример #1
0
int main (int argc, char* argv[])
{
    /* MRSG_init must be called before setting the user functions. */
    MRSG_init ();
    /* Set the task cost function. */
    MRSG_set_task_cost_f (mrsg_task_cost_function);
    /* Set the map output function. */
    MRSG_set_map_output_f (mrsg_map_output_function);
    /* Run the simulation. */
    MRSG_main ("reims-32.g5k.xml", "d-reims-32.g5k.xml", "mrsg32-reims.conf");

    return 0;
}
Пример #2
0
int main (int argc, char* argv[])
{
    /* MRA_user_init must be called before setting the user functions. */
    MRA_user_init ();
    /* MRSG_user_init must be called before setting the user functions. */
    MRSG_user_init ();
    /* Set the task cost MRA function. */
    MRA_set_task_mra_cost_f (mra_task_cost_function);
    /* Set the task cost MRSG function. */
    MRSG_set_task_cost_f (mrsg_task_cost_function);
    /* Set the MRA_map output function. */
    MRA_set_map_mra_output_f (mra_map_output_function);
    /* Set the MRSG_map output function. */
    MRSG_set_map_output_f (mrsg_map_output_function);


    /* Run the MRSG simulation. */
     //BIGHYBRID_main ("plat350-350.xml","d-plat350-350.xml","bighyb-plat350-350.conf","parser-boinc-080.txt");

     /*
       Check the args given in the command line:
         < 5 : invalid (something is missing)
         = 5 : no simgrid arg
         > 5 : simgrid arg
     */
     if(argc < 5)
     {
     	printf("usage : %s plat.xml depoly.xml plat.conf machines-trace.txt",argv[0]);
     	exit(0);
     }else if (argc == 5){
      int sg_argc = argc -4;
      MSG_init (&sg_argc, argv);
      printf("\n%s %s %s %s",argv[argc-4],argv[argc-3],argv[argc-2],argv[argc-1]);
      BIGHYBRID_main (argv[argc-4],argv[argc-3],argv[argc-2],argv[argc-1]);

     }else{
       int sg_argc = argc -4;
    //	printf("WITH SIMGRID %s\n%s %s %s %s\n",argv[1],argv[sg_argc],argv[sg_argc+1], argv[sg_argc+2],argv[sg_argc+3]);
       MSG_init (&sg_argc, argv);
      // BIGHYBRID_main (argv[sg_argc+1],argv[sg_argc+2], argv[sg_argc+3],argv[sg_argc+4]);
       BIGHYBRID_main (argv[sg_argc],argv[sg_argc+1], argv[sg_argc+2],argv[sg_argc+3]);
     }

    return 0;
}