Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
allow to specify the stack size on a per-actor basis
[simgrid.git] / src / msg / msg_legacy.cpp
index b38a12c..f39efe1 100644 (file)
@@ -27,8 +27,10 @@ msg_error_t MSG_main()
 }
 void MSG_function_register(const char* name, int (*code)(int, char**))
 {
-  simgrid::s4u::Engine::get_instance()->register_function(
-      name, [code](std::vector<std::string> args) { return simgrid::xbt::wrap_main(code, std::move(args)); });
+  simgrid::kernel::actor::ActorCodeFactory code_factory = [code](std::vector<std::string> args) {
+    return simgrid::xbt::wrap_main(code, std::move(args));
+  };
+  simgrid::s4u::Engine::get_instance()->register_function(name, code_factory);
 }
 void MSG_function_register_default(int (*code)(int, char**))
 {
@@ -51,6 +53,11 @@ int MSG_task_listen(const char* alias)
 }
 
 /* ************************** Actors *************************** */
+void MSG_process_on_exit(int_f_int_pvoid_t fun, void* data)
+{
+  sg_actor_on_exit(fun, data);
+}
+
 int MSG_process_get_PID(const_sg_actor_t actor)
 {
   return sg_actor_get_PID(actor);
@@ -320,7 +327,7 @@ void MSG_host_set_data(sg_host_t host, void* data)
 {
   return sg_host_data_set(host, data);
 }
-xbt_dict_t MSG_host_get_mounted_storage_list(sg_host_t host)
+xbt_dict_t MSG_host_get_mounted_storage_list(sg_host_t host) // XBT_ATTRIB_DEPRECATED_v330
 {
   return sg_host_get_mounted_storage_list(host);
 }