Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
028a89192d2e5affe2d1b3496494b94261ab5f62
[simgrid.git] / src / include / mc / datatypes.h
1 /* Copyright (c) 2008-2013. 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 #ifndef MC_DATATYPE_H
8 #define MC_DATATYPE_H
9 #include "xbt/misc.h"
10 #include "xbt/swag.h"
11 #include "xbt/fifo.h"
12
13 #include <dwarf.h>
14
15 SG_BEGIN_DECL()
16
17 /******************************* Transitions **********************************/
18
19 typedef struct s_mc_transition *mc_transition_t;
20
21
22 /*********** Structures for snapshot comparison **************************/
23
24 typedef struct s_mc_heap_ignore_region{
25   int block;
26   int fragment;
27   void *address;
28   size_t size;
29 }s_mc_heap_ignore_region_t, *mc_heap_ignore_region_t;
30
31 typedef struct s_stack_region{
32   void *address;
33   char *process_name;
34   void *context;
35   size_t size;
36   int block;
37 }s_stack_region_t, *stack_region_t;
38
39 void heap_ignore_region_free(mc_heap_ignore_region_t r);
40 void heap_ignore_region_free_voidp(void *r);
41
42 /************ DWARF structures *************/
43
44 typedef int e_dw_type_type;
45
46 typedef struct s_dw_type{
47   e_dw_type_type type;
48   void *id; /* Offset in the section (in hexadecimal form) */
49   char *name; /* Name of the type */
50   int byte_size; /* Size in bytes */
51   int element_count; /* Number of elements for array type */
52   char *dw_type_id; /* DW_AT_type */
53   xbt_dynar_t members; /* if DW_TAG_structure_type, DW_TAG_union_type*/
54   int is_pointer_type;
55   int offset;
56 }s_dw_type_t, *dw_type_t;
57
58 char* get_type_description(xbt_dict_t types, char *type_name);
59
60 SG_END_DECL()
61 #endif                          /* _MC_MC_H */