-// The name of this function is currently hardcoded in the code (as string).
-// Do not change it without fixing those references as well.
-static void smx_ctx_sysv_wrapper(int i1, int i2)
-{
- // Rebuild the Context* pointer from the integers:
- int ctx_addr[CTX_ADDR_LEN] = {i1, i2};
- simgrid::kernel::context::UContext* context;
- memcpy(&context, ctx_addr, sizeof context);
-
- try {
- (*context)();
- context->Context::stop();
- } catch (simgrid::kernel::context::Context::StopRequest const&) {
- XBT_DEBUG("Caught a StopRequest");
- }
- context->suspend();
-}
-