MPI_Ineighbor_alltoallv(3)
π MPI_Ineighbor_alltoallv(3) π
okay so bestie, welcome to the MPI manual page for MPI_Ineighbor_alltoallv and honestly? she's a whole vibe. it's the nonblocking version of MPI_Neighbor_alltoallv β like, the same energy, but she does NOT wait around for you to finish. no cap.
πΈ NAME πΈ
MPI_Ineighbor_alltoallv β the nonblocking version of MPI_Neighbor_alltoallv. π¦
β¨ SYNOPSIS β¨
int MPI_Ineighbor_alltoallv(const void *sendbuf, const int sendcounts[],
const int sdispls[], MPI_Datatype sendtype,
void *recvbuf, const int recvcounts[],
const int rdispls[], MPI_Datatype recvtype,
MPI_Comm comm, MPI_Request *request)
int MPI_Ineighbor_alltoallv_c(const void *sendbuf, const MPI_Count sendcounts[],
const MPI_Aint sdispls[], MPI_Datatype sendtype,
void *recvbuf, const MPI_Count recvcounts[],
const MPI_Aint rdispls[], MPI_Datatype recvtype,
MPI_Comm comm, MPI_Request *request)
like yes, there's a _c variant too. she's the same girl with the fancy MPI_Count and MPI_Aint types, and we love that for her. π
π INPUT PARAMETERS π
sendbufβ starting address of send buffer (choice). it's giving "here's where my data lives."sendcountsβ non-negative integer array (of length outdegree) specifying the number of elements to send to each neighbor (non-negative integer). so, one count per neighbor you're sending to. πsdisplsβ integer array (of length outdegree). Entry j specifies the displacement (relative tosendbuf) from which send the outgoing data to neighbor j (integer). basically the lil map that says "neighbor j, your stuff starts over here." πsendtypeβ data type of send buffer elements (handle).recvcountsβ non-negative integer array (of length indegree) specifying the number of elements that are received from each neighbor (non-negative integer).rdisplsβ integer array (of length indegree). Entry i specifies the displacement (relative torecvbuf) at which to place the incoming data from neighbor i (integer).recvtypeβ data type of receive buffer elements (handle).commβ communicator with topology structure (handle). π
π«Ά OUTPUT PARAMETERS π«Ά
recvbufβ starting address of receive buffer (choice).requestβ communication request (handle). this is your ticket to later check on her, bestie. hold onto it. β¨
π₯ THREAD AND INTERRUPT SAFETY π₯
okay so this routine is thread-safe. that means you can literally have multiple threads running it at the same time without needing any user-provided thread locks. slay. π
BUT β and this is the important part, ngl β she is not interrupt safe. typically that's because of memory allocation routines like malloc or other non-MPICH runtime routines that themselves aren't interrupt-safe. so like. know that. π
π NOTES FOR FORTRAN π
All MPI routines in Fortran (except for MPI_WTIME and MPI_WTICK) have an additional argument ierr at the end of the argument list. ierr is an integer and has the same meaning as the return value of the routine in C. In Fortran, MPI routines are subroutines, and they're invoked with the call statement.
All MPI objects (like, e.g., MPI_Datatype, MPI_Comm) are of type INTEGER in Fortran. iconic behavior honestly. π
π ERRORS π
All MPI routines (except MPI_Wtime and MPI_Wtick) return an error value; C routines as the value of the function and Fortran routines in the last argument. Before the value is returned, the current MPI error handler is called. By default, this error handler aborts the MPI job. π³ The error handler may be changed with MPI_Comm_set_errhandler (for communicators), MPI_File_set_errhandler (for files), and MPI_Win_set_errhandler (for RMA windows). The MPI-1 routine MPI_Errhandler_set may be used but its use is deprecated β like, it's still there but bestie, don't. The predefined error handler MPI_ERRORS_RETURN may be used to cause error values to be returned. Note that MPI does not guarantee that an MPI program can continue past an error; however, MPI implementations will attempt to continue whenever possible.
fr fr: default handler = the whole job just aborts. if you want error values back instead, that's what MPI_ERRORS_RETURN is for.
MPI_SUCCESSβ No error; MPI routine completed successfully. πMPI_ERR_ARGβ Invalid argument. Some argument is invalid and is not identified by a specific error class (e.g.,MPI_ERR_RANK).MPI_ERR_BUFFERβ Invalid buffer pointer. Usually a null buffer where one is not valid. πMPI_ERR_COMMβ Invalid communicator. A common error is to use a null communicator in a call (not even allowed inMPI_Comm_rank).MPI_ERR_COUNTβ Invalid count argument. Count arguments must be non-negative; a count of zero is often valid.MPI_ERR_TYPEβ Invalid datatype argument. Additionally, this error can occur if an uncommittedMPI_Datatype(seeMPI_Type_commit) is used in a communication call.MPI_ERR_OTHERβ Other error; useMPI_Error_stringto get more information about this error code.
and that's the whole page, bestie!! π§ this lil transmission came to you from the MPI source, dated 4/10/2026, filed under MPI_Ineighbor_alltoallv(3). go be a main character in your own communicator. βπ
π¦ where this page comes from
- nixos 26.05: mpich 5.0.1
- ubuntu stonking: mpich-doc 5.0.1-9 Β· other
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms