*
* \param vm VM
*/
-void simcall_vm_start(smx_host_t vm) {
- /* will jump to SIMIX_pre_vm_get_state in src/simix/smx_smurf_private.h */
- simcall_BODY_vm_set_state(vm, msg_vm_state_running);
+void simcall_vm_start(smx_host_t vm)
+{
+ /* will jump to SIMIX_pre_vm_start in src/simix/smx_smurf_private.h */
+ simcall_BODY_vm_start(vm);
}
/**
* \param vm VM
* \return The name of the physical host
*/
-const char *simcall_vm_get_phys_host(smx_host_t vm)
+void *simcall_vm_get_pm(smx_host_t vm)
{
/* will jump to SIMIX_pre_vm_migrate in src/simix/smx_smurf_private.h */
- simcall_BODY_vm_get_phys_host(vm);
+ return simcall_BODY_vm_get_pm(vm);
+}
+
+void simcall_host_get_params(smx_host_t vm, ws_params_t params)
+{
+ /* will jump to SIMIX_pre_host_get_params in src/simix/smx_smurf_private.h */
+ simcall_BODY_host_get_params(vm, params);
+}
+
+void simcall_host_set_params(smx_host_t vm, ws_params_t params)
+{
+ /* will jump to SIMIX_pre_host_set_params in src/simix/smx_smurf_private.h */
+ simcall_BODY_host_set_params(vm, params);
}
/**
{
xbt_assert(name != NULL, "Invalid parameter for simcall_rdv_get_by_name (name is NULL)");
- /* FIXME: this is a horrible lost of performance, so we hack it out by
+ /* FIXME: this is a horrible loss of performance, so we hack it out by
* skipping the simcall (for now). It works in parallel, it won't work on
* distributed but probably we will change MSG for that. */
}
+/**
+ * \ingroup simix_comm_management
+ */
+void simcall_comm_recv_bounded(smx_rdv_t rdv, void *dst_buff, size_t * dst_buff_size,
+ int (*match_fun)(void *, void *, smx_action_t), void *data, double timeout, double rate)
+{
+ xbt_assert(isfinite(timeout), "timeout is not finite!");
+ xbt_assert(rdv, "No rendez-vous point defined for recv");
+
+ if (MC_is_active()) {
+ /* the model-checker wants two separate simcalls */
+ smx_action_t comm = simcall_comm_irecv_bounded(rdv, dst_buff, dst_buff_size,
+ match_fun, data, rate);
+ simcall_comm_wait(comm, timeout);
+ }
+ else {
+ simcall_BODY_comm_recv_bounded(rdv, dst_buff, dst_buff_size,
+ match_fun, data, timeout, rate);
+ }
+}
+/**
+ * \ingroup simix_comm_management
+ */
+smx_action_t simcall_comm_irecv_bounded(smx_rdv_t rdv, void *dst_buff, size_t *dst_buff_size,
+ int (*match_fun)(void *, void *, smx_action_t), void *data, double rate)
+{
+ xbt_assert(rdv, "No rendez-vous point defined for irecv");
+
+ return simcall_BODY_comm_irecv_bounded(rdv, dst_buff, dst_buff_size,
+ match_fun, data, rate);
+}
+
+
/**
* \ingroup simix_comm_management
*/
return simcall_BODY_mc_compare_snapshots(s1, s2);
}
+int simcall_mc_random(void)
+{
+ return simcall_BODY_mc_random();
+}
+
+
#endif /* HAVE_MC */
/* ****************************************************************************************** */