SimGrid
3.16
Versatile Simulation of Distributed Systems
|
Fast context switching inspired from SystemV ucontexts.
The main difference to the System V context is that Raw Contexts are much faster because they don't preserve the signal mask when switching. This saves a system call (at least on Linux) on each context switch.
Public Member Functions | |
RawContext (std::function< void()> code, void_pfn_smxprocess_t cleanup_func, smx_actor_t process) | |
~RawContext () override | |
void | stop () override |
void | suspend () override |
void | resume () |
![]() | |
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 () |
Static Public Member Functions | |
static void | wrapper (void *arg) |
Protected Attributes | |
void * | stack_ = nullptr |
void * | stack_top_ = nullptr |
pointer to top the stack stack More... | |
Additional Inherited Members | |
![]() | |
bool | iwannadie |
simgrid::kernel::context::RawContext::RawContext | ( | std::function< void()> | code, |
void_pfn_smxprocess_t | cleanup_func, | ||
smx_actor_t | process | ||
) |
|
override |
|
overridevirtual |
Reimplemented from simgrid::kernel::context::Context.
|
overridevirtual |
Implements simgrid::kernel::context::Context.
void simgrid::kernel::context::RawContext::resume | ( | ) |
|
protected |
|
protected |
pointer to top the stack stack