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

Public GIT Repository
Another attempt at PRELOADing mmalloc (WIP)
[simgrid.git] / src / mc / Session.hpp
index 7934ec0e5847d6049a1f3578159c5d3f771e12a1..b84e6fec732c941dceca90af98d286e0659065d0 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2016-2020. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2016-2022. The 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. */
@@ -8,11 +8,11 @@
 
 #include "simgrid/forward.h"
 #include "src/mc/ModelChecker.hpp"
+#include "src/mc/remote/RemotePtr.hpp"
 
 #include <functional>
 
-namespace simgrid {
-namespace mc {
+namespace simgrid::mc {
 
 /** A model-checking session
  *
@@ -44,18 +44,16 @@ public:
   ~Session();
   void close();
 
-  void initialize();
-  void execute(Transition const& transition) const;
+  void take_initial_snapshot();
+  void restore_initial_state() const;
+
+  /** Ask to the application to check for a deadlock. If so, do an error message and throw a DeadlockError. */
+  void check_deadlock() const;
+
   void log_state() const;
 
-  void restore_initial_state() const;
   bool actor_is_enabled(aid_t pid) const;
 };
-
-// Temporary :)
-extern simgrid::mc::Session* session;
-
-}
-}
+} // namespace simgrid::mc
 
 #endif