X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/d6eb772e45cc853fc204bb5aebeb411cdfa7c929..e4ecb51dcdf597fb02340d7855dafd0da9bd9018:/src/mc/transition/TransitionActorJoin.cpp diff --git a/src/mc/transition/TransitionActorJoin.cpp b/src/mc/transition/TransitionActorJoin.cpp index 49331de852..463bfcbc6a 100644 --- a/src/mc/transition/TransitionActorJoin.cpp +++ b/src/mc/transition/TransitionActorJoin.cpp @@ -7,10 +7,6 @@ #include "simgrid/config.h" #include "xbt/asserts.h" #include "xbt/string.hpp" -#if SIMGRID_HAVE_MC -#include "src/mc/api/RemoteApp.hpp" -#include "src/mc/api/State.hpp" -#endif #include @@ -31,7 +27,17 @@ std::string ActorJoinTransition::to_string(bool verbose) const } bool ActorJoinTransition::depends(const Transition* other) const { - // Joining is indep with any other transitions: + // Joining is dependent with any transition whose + // actor is that of the `other` action. , Join i + if (other->aid_ == target_) { + return true; + } + + // Actions executed by the same actor are always dependent + if (other->aid_ == aid_) + return true; + + // Otherwise, joining is indep with any other transitions: // - It is only enabled once the target ends, and after this point it's enabled no matter what // - Other joins don't affect it, and it does not impact on the enabledness of any other transition return false;