Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Fix copyright headers
[simgrid.git] / teshsuite / simdag / partask / test_comp_only_seq.c
1 /* Copyright (c) 2007, 2009, 2010. The SimGrid Team.
2  * All rights reserved.                                                     */
3
4 /* This program is free software; you can redistribute it and/or modify it
5  * under the terms of the license (GNU LGPL) which comes with this package. */
6
7 #include <stdio.h>
8 #include <stdlib.h>
9
10 #include "simdag/simdag.h"
11
12 int main(int argc, char **argv)
13 {
14
15   double time;
16   double comm_amount[] = { 0.0 };
17   double comp_cost[] = { 1.0 };
18
19   SD_task_t task;
20
21   SD_init(&argc, argv);
22   SD_create_environment(argv[1]);
23
24   task = SD_task_create("seqtask", NULL, 1.0);
25   SD_task_schedule(task, 1, SD_workstation_get_list(), comp_cost,
26                    comm_amount, -1.0);
27
28   SD_simulate(-1.0);
29
30   time = SD_get_clock();
31
32   printf("%g\n", time);
33   fflush(stdout);
34
35   SD_task_destroy(task);
36
37   SD_exit();
38
39   return 0;
40 }