#include "smx_private.h"
#include "xbt/log.h"
#include "mc/mc.h"
-#include "mc/mc_replay.h"
+#include "src/mc/mc_replay.h"
#include "xbt/dict.h"
-#include "smpi/private.h"
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(simix_network, simix,
"SIMIX network-related synchronization");
return (detached ? NULL : other_synchro);
}
-void simcall_HANDLER_comm_recv(smx_simcall_t simcall, smx_rdv_t rdv,
+void simcall_HANDLER_comm_recv(smx_simcall_t simcall, smx_process_t receiver, smx_rdv_t rdv,
void *dst_buff, size_t *dst_buff_size,
int (*match_fun)(void *, void *, smx_synchro_t),
void (*copy_data_fun)(smx_synchro_t, void*, size_t),
void *data, double timeout, double rate)
{
- smx_synchro_t comm = SIMIX_comm_irecv(simcall->issuer, rdv, dst_buff,
+ smx_synchro_t comm = SIMIX_comm_irecv(receiver, rdv, dst_buff,
dst_buff_size, match_fun, copy_data_fun, data, rate);
SIMCALL_SET_MC_VALUE(simcall, 0);
simcall_HANDLER_comm_wait(simcall, comm, timeout);
}
-smx_synchro_t simcall_HANDLER_comm_irecv(smx_simcall_t simcall, smx_rdv_t rdv,
+smx_synchro_t simcall_HANDLER_comm_irecv(smx_simcall_t simcall, smx_process_t receiver, smx_rdv_t rdv,
void *dst_buff, size_t *dst_buff_size,
int (*match_fun)(void *, void *, smx_synchro_t),
void (*copy_data_fun)(smx_synchro_t, void*, size_t),
void *data, double rate)
{
- return SIMIX_comm_irecv(simcall->issuer, rdv, dst_buff, dst_buff_size,
+ return SIMIX_comm_irecv(receiver, rdv, dst_buff, dst_buff_size,
match_fun, copy_data_fun, data, rate);
}
XBT_DEBUG("Link failure in synchro %p between '%s' and '%s': posting an exception to the issuer: %s (%p) detached:%d",
synchro,
- synchro->comm.src_proc ? sg_host_name(synchro->comm.src_proc->host) : NULL,
- synchro->comm.dst_proc ? sg_host_name(synchro->comm.dst_proc->host) : NULL,
+ synchro->comm.src_proc ? sg_host_get_name(synchro->comm.src_proc->host) : NULL,
+ synchro->comm.dst_proc ? sg_host_get_name(synchro->comm.dst_proc->host) : NULL,
simcall->issuer->name, simcall->issuer, synchro->comm.detached);
if (synchro->comm.src_proc == simcall->issuer) {
XBT_DEBUG("I'm source");
XBT_DEBUG("Copying comm %p data from %s (%p) -> %s (%p) (%zu bytes)",
comm,
- comm->comm.src_proc ? sg_host_name(comm->comm.src_proc->host) : "a finished process",
+ comm->comm.src_proc ? sg_host_get_name(comm->comm.src_proc->host) : "a finished process",
comm->comm.src_buff,
- comm->comm.dst_proc ? sg_host_name(comm->comm.dst_proc->host) : "a finished process",
+ comm->comm.dst_proc ? sg_host_get_name(comm->comm.dst_proc->host) : "a finished process",
comm->comm.dst_buff, buff_size);
/* Copy at most dst_buff_size bytes of the message to receiver's buffer */