-/* Copyright (c) 2013-2017. The SimGrid Team.
+/* Copyright (c) 2013-2021. The SimGrid Team.
* All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* [5] [5] [5] [5] [5] [5]
*/
- #include "../colls_private.h"
+#include "../colls_private.hpp"
namespace simgrid{
namespace smpi{
int
-Coll_allgather_ompi_neighborexchange::allgather(void *sbuf, int scount,
+allgather__ompi_neighborexchange(const void *sbuf, int scount,
MPI_Datatype sdtype,
void* rbuf, int rcount,
MPI_Datatype rdtype,
int i, even_rank;
int err = 0;
ptrdiff_t slb, rlb, sext, rext;
- char *tmpsend = NULL, *tmprecv = NULL;
+ char *tmpsend = nullptr, *tmprecv = nullptr;
size = comm->size();
rank = comm->rank();
XBT_DEBUG(
"coll:tuned:allgather_intra_neighborexchange WARNING: odd size %d, switching to ring algorithm",
size);
- return Coll_allgather_ring::allgather(sbuf, scount, sdtype,
- rbuf, rcount, rdtype,
- comm);
+ return allgather__ring(sbuf, scount, sdtype,
+ rbuf, rcount, rdtype,
+ comm);
}
XBT_DEBUG(
- Rest of the steps:
update recv_data_from according to offset, and
exchange two blocks with appropriate neighbor.
- the send location becomes previous receve location.
+ the send location becomes previous receive location.
*/
tmprecv = (char*)rbuf + neighbor[0] * rcount * rext;
tmpsend = (char*)rbuf + rank * rcount * rext;