Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Better responsabilities splitup between CheckerSide and RemoteProcessMemory
[simgrid.git] / src / mc / sosp / RemoteProcessMemory.hpp
index bb2d04a..7b4dff5 100644 (file)
 
 namespace simgrid::mc {
 
-class ActorInformation {
-public:
-  /** MCed address of the process */
-  RemotePtr<kernel::actor::ActorImpl> address{nullptr};
-  Remote<kernel::actor::ActorImpl> copy;
-
-  /** Hostname (owned by `mc_model_checker->hostnames_`) */
-  const std::string* hostname = nullptr;
-  std::string name;
-
-  void clear()
-  {
-    name.clear();
-    address  = nullptr;
-    hostname = nullptr;
-  }
-};
-
 struct IgnoredRegion {
   std::uint64_t addr;
   std::size_t size;
@@ -50,14 +32,14 @@ struct IgnoredHeapRegion {
   std::size_t size;
 };
 
-/** The Application's process memory, seen from the Checker perspective
- *
- *  Responsibilities:
+/** The Application's process memory, seen from the Checker perspective. This class is not needed if you don't need to
+ * introspect the application process.
  *
- *  - reading from the process memory (`AddressSpace`);
- *  - accessing the system state of the process (heap, …);
- *  - stack unwinding;
- *  - etc.
+ *  Responsabilities:
+ *    - reading from the process memory (`AddressSpace`);
+ *    - accessing the system state of the process (heap, …);
+ *    - stack unwinding;
+ *    - etc.
  */
 class RemoteProcessMemory final : public AddressSpace {
 private:
@@ -132,17 +114,11 @@ public:
   std::vector<IgnoredRegion> const& ignored_regions() const { return ignored_regions_; }
   void ignore_region(std::uint64_t address, std::size_t size);
 
-  pid_t pid() const { return pid_; }
-
   bool in_maestro_stack(RemotePtr<void> p) const
   {
     return p >= this->maestro_stack_start_ && p < this->maestro_stack_end_;
   }
 
-  bool running() const { return running_; }
-
-  void terminate() { running_ = false; }
-
   void ignore_global_variable(const char* name) const
   {
     for (std::shared_ptr<ObjectInformation> const& info : this->object_infos)
@@ -165,8 +141,7 @@ private:
   void refresh_heap();
   void refresh_malloc_info();
 
-  pid_t pid_    = -1;
-  bool running_ = false;
+  pid_t pid_ = -1;
   std::vector<xbt::VmMap> memory_map_;
   RemotePtr<void> maestro_stack_start_;
   RemotePtr<void> maestro_stack_end_;