With the reference to the official documentation of the specific function:
#include <mpi.h>
int MPI_Comm_split_type(MPI_Comm comm, int split_type, int key,
MPI_Info info, MPI_Comm *newcomm)
from here: https://www.open-mpi.org/doc/v3.0/man3/MPI_Comm_split_type.3.php
As described in the above link, the int key argument is used for the following purpose: Within each subgroup, the processes are ranked in the order defined by the value of the argument key, with ties broken according to their rank in the old group
I am not really sure I understand it, thus my question is:
Does the value under key is going to be the new rank value of each processes within the new communicator? Do I need to pass explicitly the rank/Id of each process in this way?
key
if you want to control how tanks will be assigned to MPI tasks in the new communicator. If you do not need/care for a specific ranking, then simply usekey=0
on all ranks. - Gilles Gouaillardet