]> AND Public Git Repository - simgrid.git/blobdiff - src/mc/mc_private.h
Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
model-checker : code refactoring for get_hash_global
[simgrid.git] / src / mc / mc_private.h
index 0d55eef8e3f8da2e86f1ccb54c204f1bf9e1f49e..b2f9a1b3ebe11fa53ac3b339d53b6e0971184086 100644 (file)
@@ -41,6 +41,8 @@ typedef struct s_mc_snapshot{
   size_t *stack_sizes;
   xbt_dynar_t stacks;
   xbt_dynar_t to_ignore;
+  char hash_global[41];
+  char hash_local[41];
 } s_mc_snapshot_t, *mc_snapshot_t;
 
 typedef struct s_mc_snapshot_stack{
@@ -58,9 +60,12 @@ mc_snapshot_t MC_take_snapshot(void);
 void MC_restore_snapshot(mc_snapshot_t);
 void MC_free_snapshot(mc_snapshot_t);
 void snapshot_stack_free_voidp(void *s);
+int is_stack_ignore_variable(char *frame, char *var_name);
 
 /********************************* MC Global **********************************/
 extern double *mc_time;
+extern FILE *dot_output;
+extern const char* colors[10];
 
 int MC_deadlock_check(void);
 void MC_replay(xbt_fifo_t stack, int start);
@@ -69,8 +74,9 @@ void MC_wait_for_requests(void);
 void MC_show_deadlock(smx_simcall_t req);
 void MC_show_stack_safety(xbt_fifo_t stack);
 void MC_dump_stack_safety(xbt_fifo_t stack);
-
-int SIMIX_pre_mc_random(smx_simcall_t simcall, int min, int max);
+void MC_init(void);
+void MC_init_dot_output(void);
+int SIMIX_pre_mc_random(smx_simcall_t simcall);
 
 /********************************* Requests ***********************************/
 int MC_request_depend(smx_simcall_t req1, smx_simcall_t req2);
@@ -81,6 +87,7 @@ int MC_request_is_visible(smx_simcall_t req);
 int MC_request_is_enabled(smx_simcall_t req);
 int MC_request_is_enabled_by_idx(smx_simcall_t req, unsigned int idx);
 int MC_process_is_enabled(smx_process_t process);
+char *MC_request_get_dot_output(smx_simcall_t req, int value);
 
 
 /******************************** States **************************************/
@@ -88,6 +95,7 @@ int MC_process_is_enabled(smx_process_t process);
 typedef enum {
   MC_NOT_INTERLEAVE=0,      /* Do not interleave (do not execute) */
   MC_INTERLEAVE,            /* Interleave the process (one or more request) */
+  MC_MORE_INTERLEAVE,       /* Interleave twice the process (for mc_random simcall) */
   MC_DONE                   /* Already interleaved */
 } e_mc_process_state_t;
 
@@ -108,6 +116,7 @@ typedef struct mc_state {
   int req_num;                      /* The request number (in the case of a
                                        multi-request like waitany ) */
   mc_snapshot_t system_state;      /* Snapshot of system state */
+  int num;
 } s_mc_state_t, *mc_state_t;
 
 mc_state_t MC_state_new(void);
@@ -222,6 +231,8 @@ typedef struct s_mc_comparison_times{
   double libsimgrid_global_variables_comparison_time;
   double heap_comparison_time;
   double stacks_comparison_time;
+  double hash_global_variables_comparison_time;
+  double hash_local_variables_comparison_time;
 }s_mc_comparison_times_t, *mc_comparison_times_t;
 
 extern mc_comparison_times_t mc_comp_times;
@@ -246,7 +257,6 @@ extern mc_global_t initial_state_safety;
 
 void MC_dpor_init(void);
 void MC_dpor(void);
-void MC_init(void);
 
 typedef struct s_mc_safety_visited_state{
   mc_snapshot_t system_state;