1 /* This program is free software; you can redistribute it and/or modify it
2 * under the terms of the license (GNU LGPL) which comes with this package. */
4 #ifndef GRAS_STUB_GENERATOR_H
5 #define GRAS_STUB_GENERATOR_H
11 #include "simdag/simdag.h"
14 #include "xbt/dynar.h"
16 #include "xbt/sysdep.h"
17 #include "xbt/function_types.h"
19 #include "surf/surfxml_parse.h"
20 #include "surf/surf_private.h"
21 #include "surf/surf.h"
22 #include "portable.h" /* Needed for the time of the SIMIX convertion */
26 xbt_dict_t process_function_set;
27 xbt_dynar_t process_list;
28 xbt_dict_t machine_set;
30 typedef struct s_process_t {
38 void s_process_free(void *process);
41 void generate_sim(const char *project);
42 void generate_rl(const char *project);
43 void generate_makefile_am(const char *project);
44 void generate_makefile_local(const char *project);
46 /* ********************************************************************************* */
47 /* Console functions */
48 /* ********************************************************************************* */
50 typedef struct t_AS_attr {
53 } AS_attr, *p_AS_attr;
55 typedef struct t_host_attr {
57 // Mandatory attributes
60 // Optional attributes
62 const char *power_trace;
64 const char *state_trace;
66 //deployment attribute
68 xbt_dynar_t args_list;
69 } host_attr, *p_host_attr;
72 typedef struct t_link_attr {
73 //mandatory attributes
77 // Optional attributes
78 const char *bandwidth_trace;
79 const char *latency_trace;
80 const char *state_trace;
83 } link_attr, *p_link_attr;
86 typedef struct t_route_attr {
91 } route_attr, *p_route_attr;
95 int console_add_host(lua_State*);
96 int console_add_link(lua_State*);
97 int console_add_route(lua_State*);
98 int console_add_AS(lua_State*);
99 int console_set_function(lua_State*);
101 int console_parse_platform(void);
102 int console_parse_application(void);
103 int console_parse_platform_wsL07(void);