Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
unify how threaded and parallelisable context factories find context_self
[simgrid.git] / src / kernel / context / ContextRaw.hpp
index fb17bc6..e1ececd 100644 (file)
@@ -31,8 +31,8 @@ public:
   virtual void resume() = 0;
 
   static void swap(RawContext* from, RawContext* to);
-  static RawContext* getMaestro() { return maestro_context_; }
-  static void setMaestro(RawContext* maestro) { maestro_context_ = maestro; }
+  static RawContext* get_maestro() { return maestro_context_; }
+  static void set_maestro(RawContext* maestro) { maestro_context_ = maestro; }
 
 private:
   static RawContext* maestro_context_;
@@ -65,7 +65,6 @@ private:
   static unsigned long process_index_;
 };
 
-#if HAVE_THREAD_CONTEXTS
 class ParallelRawContext : public RawContext {
 public:
   ParallelRawContext(std::function<void()> code, void_pfn_smxprocess_t cleanup_func, smx_actor_t process)
@@ -85,7 +84,6 @@ private:
   static std::atomic<uintptr_t> threads_working_;
   static uintptr_t thread_local worker_id_;
 };
-#endif
 
 class RawContextFactory : public ContextFactory {
 public: