SimGrid  3.14.159
Versatile Simulation of Distributed Systems
simgrid::kernel::context::ParallelUContext Class Reference
Inheritance diagram for simgrid::kernel::context::ParallelUContext:
simgrid::kernel::context::UContext simgrid::kernel::context::Context

Public Member Functions

 ParallelUContext (std::function< void()> code, void_pfn_smxprocess_t cleanup_func, smx_actor_t process)
 
void stop () override
 
void suspend () override
 Yield. More...
 
void resume ()
 Run one particular simulated process on the current thread. More...
 
- Public Member Functions inherited from simgrid::kernel::context::UContext
 UContext (std::function< void()> code, void_pfn_smxprocess_t cleanup_func, smx_actor_t process)
 
 ~UContext () override
 
- Public Member Functions inherited from simgrid::kernel::context::Context
 Context (std::function< void()> code, void_pfn_smxprocess_t cleanup_func, smx_actor_t process)
 
void operator() ()
 
bool has_code () const
 
smx_actor_t process ()
 
void set_cleanup (void_pfn_smxprocess_t cleanup)
 
virtual ~Context ()
 

Additional Inherited Members

- Public Attributes inherited from simgrid::kernel::context::UContext
friend UContextFactory
 
- Public Attributes inherited from simgrid::kernel::context::Context
bool iwannadie
 
- Protected Attributes inherited from simgrid::kernel::context::UContext
ucontext_t uc_
 
char * stack_ = nullptr
 

Constructor & Destructor Documentation

§ ParallelUContext()

simgrid::kernel::context::ParallelUContext::ParallelUContext ( std::function< void()>  code,
void_pfn_smxprocess_t  cleanup_func,
smx_actor_t  process 
)
inline

Member Function Documentation

§ stop()

void simgrid::kernel::context::ParallelUContext::stop ( )
overridevirtual

Reimplemented from simgrid::kernel::context::Context.

§ suspend()

void simgrid::kernel::context::ParallelUContext::suspend ( )
overridevirtual

Yield.

This function is called when a simulated process wants to yield back to the maestro in a blocking simcall. This naturally occurs within SIMIX_context_suspend(self->context), called from SIMIX_process_yield() Actually, it does not really yield back to maestro, but into the next process that must be executed. If no one is to be executed, then it yields to the initial soul that was in this working thread (that was saved in resume_parallel).

Implements simgrid::kernel::context::Context.

§ resume()

void simgrid::kernel::context::ParallelUContext::resume ( )

Run one particular simulated process on the current thread.


The documentation for this class was generated from the following file: