Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
model-checker : move print statistics if property is valid
[simgrid.git] / src / mc / mc_dpor.c
index 3d5b514..ed50ac0 100644 (file)
@@ -1,10 +1,9 @@
-/* Copyright (c) 2008 Martin Quinson, Cristian Rosa.
-   All rights reserved.                                          */
+/* Copyright (c) 2008-2012. Da SimGrid Team. All rights reserved.           */
 
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
 
-#include "private.h"
+#include "mc_private.h"
 
 XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_dpor, mc,
                                 "Logging specific to MC DPOR exploration");
@@ -53,7 +52,7 @@ void MC_dpor(void)
 {
   char *req_str;
   int value;
-  smx_req_t req = NULL, prev_req = NULL;
+  smx_simcall_t req = NULL, prev_req = NULL;
   mc_state_t state = NULL, prev_state = NULL, next_state = NULL;
   smx_process_t process = NULL;
   xbt_fifo_item_t item = NULL;
@@ -88,7 +87,7 @@ void MC_dpor(void)
       mc_stats->executed_transitions++;
 
       /* Answer the request */
-      SIMIX_request_pre(req, value); /* After this call req is no longer usefull */
+      SIMIX_simcall_pre(req, value); /* After this call req is no longer usefull */
 
       /* Wait for requests (schedules processes) */
       MC_wait_for_requests();
@@ -174,6 +173,7 @@ void MC_dpor(void)
       MC_UNSET_RAW_MEM;
     }
   }
+  MC_print_statistics(mc_stats);
   MC_UNSET_RAW_MEM;
   return;
 }
@@ -232,7 +232,7 @@ void MC_dpor_stateful(){
 
   int value;
   mc_state_t next_graph_state = NULL;
-  smx_req_t req = NULL, prev_req = NULL;
+  smx_simcall_t req = NULL, prev_req = NULL;
   char *req_str;
   xbt_fifo_item_t item = NULL;
 
@@ -268,7 +268,7 @@ void MC_dpor_stateful(){
       mc_stats->executed_transitions++;
       
       /* Answer the request */
-      SIMIX_request_pre(req, value);
+      SIMIX_simcall_pre(req, value);
       
       /* Wait for requests (schedules processes) */
       MC_wait_for_requests();