X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/c9fa3b2f54b1793ba420c06fed2f7bf4ec04b30f..edde8f7fbc1b74a81551bf9eb7bac1935b999296:/src/msg/msg_global.c?ds=sidebyside diff --git a/src/msg/msg_global.c b/src/msg/msg_global.c index 7ac93dd4f9..99240fd137 100644 --- a/src/msg/msg_global.c +++ b/src/msg/msg_global.c @@ -153,6 +153,51 @@ MSG_error_t MSG_main(void) return MSG_OK; } +MSG_error_t MSG_main_stateful(void) +{ + /* Clean IO before the run */ + fflush(stdout); + fflush(stderr); + + if (MC_IS_ENABLED) { + MC_modelcheck_stateful(); + } + else { + SIMIX_run(); + } + return MSG_OK; +} + +MSG_error_t MSG_main_liveness_stateful(xbt_automaton_t a) +{ + /* Clean IO before the run */ + fflush(stdout); + fflush(stderr); + + if (MC_IS_ENABLED) { + MC_modelcheck_liveness_stateful(a); + } + else { + SIMIX_run(); + } + return MSG_OK; +} + +MSG_error_t MSG_main_liveness_stateless(xbt_automaton_t a, char *prgm) +{ + /* Clean IO before the run */ + fflush(stdout); + fflush(stderr); + + if (MC_IS_ENABLED) { + MC_modelcheck_liveness_stateless(a, prgm); + } + else { + SIMIX_run(); + } + return MSG_OK; +} + /** \ingroup msg_simulation * \brief Kill all running process