Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Python: Add Comm.wait_any
[simgrid.git] / src / simix / popping_generated.cpp
index 1d6a4a6..9306f6c 100644 (file)
@@ -4,7 +4,7 @@
 /*                    DO NOT EVER CHANGE THIS FILE                    */
 /*                                                                    */
 /* change simcalls specification in src/simix/simcalls.in             */
-/* Copyright (c) 2014-2017. The SimGrid Team. All rights reserved.    */
+/* Copyright (c) 2014-2019. The SimGrid Team. All rights reserved.    */
 /**********************************************************************/
 
 /*
 #if SIMGRID_HAVE_MC
 #include "src/mc/mc_forward.hpp"
 #endif
+#include "src/kernel/activity/ConditionVariableImpl.hpp"
 
 XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(simix_popping);
 
 /** @brief Simcalls' names (generated from src/simix/simcalls.in) */
 const char* simcall_names[] = {
     "SIMCALL_NONE",
-    "SIMCALL_PROCESS_KILLALL",
-    "SIMCALL_PROCESS_CLEANUP",
     "SIMCALL_PROCESS_SUSPEND",
     "SIMCALL_PROCESS_JOIN",
     "SIMCALL_PROCESS_SLEEP",
-    "SIMCALL_EXECUTION_START",
-    "SIMCALL_EXECUTION_PARALLEL_START",
     "SIMCALL_EXECUTION_WAIT",
-    "SIMCALL_PROCESS_ON_EXIT",
-    "SIMCALL_COMM_IPROBE",
+    "SIMCALL_EXECUTION_TEST",
     "SIMCALL_COMM_SEND",
     "SIMCALL_COMM_ISEND",
     "SIMCALL_COMM_RECV",
@@ -46,17 +42,12 @@ const char* simcall_names[] = {
     "SIMCALL_MUTEX_LOCK",
     "SIMCALL_MUTEX_TRYLOCK",
     "SIMCALL_MUTEX_UNLOCK",
-    "SIMCALL_COND_INIT",
-    "SIMCALL_COND_SIGNAL",
     "SIMCALL_COND_WAIT",
     "SIMCALL_COND_WAIT_TIMEOUT",
-    "SIMCALL_COND_BROADCAST",
     "SIMCALL_SEM_ACQUIRE",
     "SIMCALL_SEM_ACQUIRE_TIMEOUT",
-    "SIMCALL_STORAGE_READ",
-    "SIMCALL_STORAGE_WRITE",
+    "SIMCALL_IO_WAIT",
     "SIMCALL_MC_RANDOM",
-    "SIMCALL_SET_CATEGORY",
     "SIMCALL_RUN_KERNEL",
     "SIMCALL_RUN_BLOCKING",
 };
@@ -69,19 +60,9 @@ const char* simcall_names[] = {
 void SIMIX_simcall_handle(smx_simcall_t simcall, int value) {
   XBT_DEBUG("Handling simcall %p: %s", simcall, SIMIX_simcall_name(simcall->call));
   SIMCALL_SET_MC_VALUE(simcall, value);
-  if (simcall->issuer->context->iwannadie && simcall->call != SIMCALL_PROCESS_CLEANUP)
+  if (simcall->issuer->context_->iwannadie)
     return;
   switch (simcall->call) {
-case SIMCALL_PROCESS_KILLALL:
-  simcall_HANDLER_process_killall(simcall, simgrid::simix::unmarshal<int>(simcall->args[0]));
-  SIMIX_simcall_answer(simcall);
-  break;
-
-case SIMCALL_PROCESS_CLEANUP:
-  SIMIX_process_cleanup(simgrid::simix::unmarshal<smx_actor_t>(simcall->args[0]));
-  SIMIX_simcall_answer(simcall);
-  break;
-
 case SIMCALL_PROCESS_SUSPEND:
   simcall_HANDLER_process_suspend(simcall, simgrid::simix::unmarshal<smx_actor_t>(simcall->args[0]));
   break;
@@ -94,28 +75,14 @@ case SIMCALL_PROCESS_SLEEP:
   simcall_HANDLER_process_sleep(simcall, simgrid::simix::unmarshal<double>(simcall->args[0]));
   break;
 
-case SIMCALL_EXECUTION_START:
-  simgrid::simix::marshal<boost::intrusive_ptr<simgrid::kernel::activity::ExecImpl>>(simcall->result, simcall_HANDLER_execution_start(simcall, simgrid::simix::unmarshal<const char*>(simcall->args[0]), simgrid::simix::unmarshal<double>(simcall->args[1]), simgrid::simix::unmarshal<double>(simcall->args[2]), simgrid::simix::unmarshal<double>(simcall->args[3])));
-  SIMIX_simcall_answer(simcall);
-  break;
-
-case SIMCALL_EXECUTION_PARALLEL_START:
-  simgrid::simix::marshal<boost::intrusive_ptr<simgrid::kernel::activity::ExecImpl>>(simcall->result, SIMIX_execution_parallel_start(simgrid::simix::unmarshal<const char*>(simcall->args[0]), simgrid::simix::unmarshal<int>(simcall->args[1]), simgrid::simix::unmarshal<sg_host_t*>(simcall->args[2]), simgrid::simix::unmarshal<double*>(simcall->args[3]), simgrid::simix::unmarshal<double*>(simcall->args[4]), simgrid::simix::unmarshal<double>(simcall->args[5]), simgrid::simix::unmarshal<double>(simcall->args[6])));
-  SIMIX_simcall_answer(simcall);
-  break;
-
 case SIMCALL_EXECUTION_WAIT:
-  simcall_HANDLER_execution_wait(simcall, simgrid::simix::unmarshal<boost::intrusive_ptr<simgrid::kernel::activity::ActivityImpl>>(simcall->args[0]));
+  simcall_HANDLER_execution_wait(simcall,
+                                 simgrid::simix::unmarshal<simgrid::kernel::activity::ExecImpl*>(simcall->args[0]));
   break;
 
-case SIMCALL_PROCESS_ON_EXIT:
-  SIMIX_process_on_exit(simgrid::simix::unmarshal<smx_actor_t>(simcall->args[0]), simgrid::simix::unmarshal<int_f_pvoid_pvoid_t>(simcall->args[1]), simgrid::simix::unmarshal<void*>(simcall->args[2]));
-  SIMIX_simcall_answer(simcall);
-  break;
-
-case SIMCALL_COMM_IPROBE:
-  simgrid::simix::marshal<boost::intrusive_ptr<simgrid::kernel::activity::ActivityImpl>>(simcall->result, simcall_HANDLER_comm_iprobe(simcall, simgrid::simix::unmarshal<smx_mailbox_t>(simcall->args[0]), simgrid::simix::unmarshal<int>(simcall->args[1]), simgrid::simix::unmarshal<simix_match_func_t>(simcall->args[2]), simgrid::simix::unmarshal<void*>(simcall->args[3])));
-  SIMIX_simcall_answer(simcall);
+case SIMCALL_EXECUTION_TEST:
+  simcall_HANDLER_execution_test(simcall,
+                                 simgrid::simix::unmarshal<simgrid::kernel::activity::ExecImpl*>(simcall->args[0]));
   break;
 
 case SIMCALL_COMM_SEND:
@@ -137,19 +104,24 @@ case SIMCALL_COMM_IRECV:
   break;
 
 case SIMCALL_COMM_WAITANY:
-  simcall_HANDLER_comm_waitany(simcall, simgrid::simix::unmarshal<xbt_dynar_t>(simcall->args[0]), simgrid::simix::unmarshal<double>(simcall->args[1]));
+  simcall_HANDLER_comm_waitany(
+      simcall, simgrid::simix::unmarshal<simgrid::kernel::activity::CommImpl**>(simcall->args[0]),
+      simgrid::simix::unmarshal<size_t>(simcall->args[1]), simgrid::simix::unmarshal<double>(simcall->args[2]));
   break;
 
 case SIMCALL_COMM_WAIT:
-  simcall_HANDLER_comm_wait(simcall, simgrid::simix::unmarshal<boost::intrusive_ptr<simgrid::kernel::activity::ActivityImpl>>(simcall->args[0]), simgrid::simix::unmarshal<double>(simcall->args[1]));
+  simcall_HANDLER_comm_wait(simcall, simgrid::simix::unmarshal<simgrid::kernel::activity::CommImpl*>(simcall->args[0]),
+                            simgrid::simix::unmarshal<double>(simcall->args[1]));
   break;
 
 case SIMCALL_COMM_TEST:
-  simcall_HANDLER_comm_test(simcall, simgrid::simix::unmarshal<boost::intrusive_ptr<simgrid::kernel::activity::ActivityImpl>>(simcall->args[0]));
+  simcall_HANDLER_comm_test(simcall, simgrid::simix::unmarshal<simgrid::kernel::activity::CommImpl*>(simcall->args[0]));
   break;
 
 case SIMCALL_COMM_TESTANY:
-  simcall_HANDLER_comm_testany(simcall, simgrid::simix::unmarshal<boost::intrusive_ptr<simgrid::kernel::activity::ActivityImpl>*>(simcall->args[0]), simgrid::simix::unmarshal<size_t>(simcall->args[1]));
+  simcall_HANDLER_comm_testany(simcall,
+                               simgrid::simix::unmarshal<simgrid::kernel::activity::CommImpl**>(simcall->args[0]),
+                               simgrid::simix::unmarshal<size_t>(simcall->args[1]));
   break;
 
 case SIMCALL_MUTEX_LOCK:
@@ -166,16 +138,6 @@ case SIMCALL_MUTEX_UNLOCK:
   SIMIX_simcall_answer(simcall);
   break;
 
-case SIMCALL_COND_INIT:
-  simgrid::simix::marshal<smx_cond_t>(simcall->result, SIMIX_cond_init());
-  SIMIX_simcall_answer(simcall);
-  break;
-
-case SIMCALL_COND_SIGNAL:
-  SIMIX_cond_signal(simgrid::simix::unmarshal<smx_cond_t>(simcall->args[0]));
-  SIMIX_simcall_answer(simcall);
-  break;
-
 case SIMCALL_COND_WAIT:
   simcall_HANDLER_cond_wait(simcall, simgrid::simix::unmarshal<smx_cond_t>(simcall->args[0]), simgrid::simix::unmarshal<smx_mutex_t>(simcall->args[1]));
   break;
@@ -184,11 +146,6 @@ case SIMCALL_COND_WAIT_TIMEOUT:
   simcall_HANDLER_cond_wait_timeout(simcall, simgrid::simix::unmarshal<smx_cond_t>(simcall->args[0]), simgrid::simix::unmarshal<smx_mutex_t>(simcall->args[1]), simgrid::simix::unmarshal<double>(simcall->args[2]));
   break;
 
-case SIMCALL_COND_BROADCAST:
-  SIMIX_cond_broadcast(simgrid::simix::unmarshal<smx_cond_t>(simcall->args[0]));
-  SIMIX_simcall_answer(simcall);
-  break;
-
 case SIMCALL_SEM_ACQUIRE:
   simcall_HANDLER_sem_acquire(simcall, simgrid::simix::unmarshal<smx_sem_t>(simcall->args[0]));
   break;
@@ -197,14 +154,8 @@ case SIMCALL_SEM_ACQUIRE_TIMEOUT:
   simcall_HANDLER_sem_acquire_timeout(simcall, simgrid::simix::unmarshal<smx_sem_t>(simcall->args[0]), simgrid::simix::unmarshal<double>(simcall->args[1]));
   break;
 
-case SIMCALL_STORAGE_READ:
-  simcall_HANDLER_storage_read(simcall, simgrid::simix::unmarshal<surf_storage_t>(simcall->args[0]),
-                               simgrid::simix::unmarshal<sg_size_t>(simcall->args[1]));
-  break;
-
-case SIMCALL_STORAGE_WRITE:
-  simcall_HANDLER_storage_write(simcall, simgrid::simix::unmarshal<surf_storage_t>(simcall->args[0]),
-                                simgrid::simix::unmarshal<sg_size_t>(simcall->args[1]));
+case SIMCALL_IO_WAIT:
+  simcall_HANDLER_io_wait(simcall, simgrid::simix::unmarshal<simgrid::kernel::activity::IoImpl*>(simcall->args[0]));
   break;
 
 case SIMCALL_MC_RANDOM:
@@ -212,11 +163,6 @@ case SIMCALL_MC_RANDOM:
   SIMIX_simcall_answer(simcall);
   break;
 
-case SIMCALL_SET_CATEGORY:
-  SIMIX_set_category(simgrid::simix::unmarshal<boost::intrusive_ptr<simgrid::kernel::activity::ActivityImpl>>(simcall->args[0]), simgrid::simix::unmarshal<const char*>(simcall->args[1]));
-  SIMIX_simcall_answer(simcall);
-  break;
-
 case SIMCALL_RUN_KERNEL:
   SIMIX_run_kernel(simgrid::simix::unmarshal<std::function<void()> const*>(simcall->args[0]));
   SIMIX_simcall_answer(simcall);
@@ -228,11 +174,8 @@ case SIMCALL_RUN_BLOCKING:
     case NUM_SIMCALLS:
       break;
     case SIMCALL_NONE:
-      THROWF(arg_error,0,"Asked to do the noop syscall on %s@%s",
-          simcall->issuer->name.c_str(),
-          sg_host_get_name(simcall->issuer->host)
-          );
-      break;
+      THROWF(arg_error, 0, "Asked to do the noop syscall on %s@%s", simcall->issuer->get_cname(),
+             sg_host_get_name(simcall->issuer->get_host()));
     default:
       THROW_IMPOSSIBLE;
   }