Debian Codegraph @

clang-tools-extra/docs/clang-tidy/checks/mpi/type-mismatch.rst

raw
1 .. title:: clang-tidy - mpi-type-mismatch
2
3 mpi-type-mismatch
4 =================
5
6 This check verifies if buffer type and MPI (Message Passing Interface) datatype
7 pairs match for used MPI functions. All MPI datatypes defined by the MPI
8 standard (3.1) are verified by this check. User defined typedefs, custom MPI
9 datatypes and null pointer constants are skipped, in the course of verification.
10
11 Example:
12
13 .. code-block:: c++
14
15 // In this case, the buffer type matches MPI datatype.
16 char buf;
17 MPI_Send(&buf, 1, MPI_CHAR, 0, 0, MPI_COMM_WORLD);
18
19 // In the following case, the buffer type does not match MPI datatype.
20 int buf;
21 MPI_Send(&buf, 1, MPI_CHAR, 0, 0, MPI_COMM_WORLD);