From: Gabriel Corona Date: Sat, 25 Jul 2015 09:02:26 +0000 (+0200) Subject: [mc] Move MC_random is mc_base.cpp X-Git-Tag: v3_12~419 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/4436adf7710dc39c6555fcd87701db50c654bf71?hp=a35e717fdc32c356eebc3dfdd71d1a8639af20a6 [mc] Move MC_random is mc_base.cpp --- diff --git a/src/mc/mc_base.cpp b/src/mc/mc_base.cpp index c0f9ab9f14..521b96a08a 100644 --- a/src/mc/mc_base.cpp +++ b/src/mc/mc_base.cpp @@ -30,6 +30,15 @@ extern "C" { XBT_LOG_NEW_CATEGORY(mc, "All MC categories"); +int MC_random(int min, int max) +{ + xbt_assert(mc_mode != MC_MODE_SERVER); + /* TODO, if the MC is disabled we do not really need to make a simcall for + * this :) */ + /* FIXME: return mc_current_state->executed_transition->random.value; */ + return simcall_mc_random(min, max); +} + void MC_wait_for_requests(void) { #ifdef HAVE_MC diff --git a/src/mc/mc_client_api.cpp b/src/mc/mc_client_api.cpp index bdc12a2150..372f3c4082 100644 --- a/src/mc/mc_client_api.cpp +++ b/src/mc/mc_client_api.cpp @@ -30,14 +30,7 @@ XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_client_api, mc, } -int MC_random(int min, int max) -{ - xbt_assert(mc_mode != MC_MODE_SERVER); - /* TODO, if the MC is disabled we do not really need to make a simcall for - * this :) */ - /* FIXME: return mc_current_state->executed_transition->random.value; */ - return simcall_mc_random(min, max); -} +// MC_random() is in mc_base.cpp void MC_assert(int prop) {