MPI_Type_get_envelope - Returns the number and type of
input arguments
SYNOPSIS
C:
#include "mpi.h"
int MPI_Type_get_envelope(MPI_Datatype datatype, int *num_integers,
int *num_addresses, int *num_datatypes, int *combiner)
Fortran:
INCLUDE "mpif.h" (or USE MPI)
INTEGER datatype, num_integers, num_addresses,
num_datatypes, combiner, ierror
CALL MPI_TYPE_GET_ENVELOPE(datatype, num_integers, num_addresses,
num_datatypes, combiner, ierror)
DESCRIPTION
For a specified data type, MPI_Type_get_envelope returns
information on the number and type of input arguments that
were used in the call that created the data type. The
returned values can be used to provide sufficiently large
arrays in the decoding routine, MPI_Type_get_contents.
MPI_Type_get_envelope accepts the following arguments:
datatype Specifies the data type to be accessed
(handle)
num_integers Returns the number of input integers
used in the call that constructs the
combiner (nonnegative integer)
num_addresses Returns the number of input addresses
used in the call that constructs the
combiner (nonnegative integer)
num_datatypes Returns the number of input data types
used in the call that constructs the
combiner (nonnegative integer)
combiner Reflects the MPI data type constructor
call that was used in creating the
data type (state)
ierror Specifies the return code value for
successful completion, which is in
MPI_SUCCESS. MPI_SUCCESS is defined
By requiring that the combiner reflect the constructor
used in the creation of the data type, the decoded
information can be used to effectively recreate the
calling sequence used in the original creation. One call
is effectively the same as another when the information
obtained from MPI_Type_get_contents can be used with
either to produce the same outcome. In some MPI
implementations, C calls, MPI_Type_hindexed and
MPI_Type_create_hindexed, are always effectively the same,
while the Fortran call, MPI_TYPE_HINDEXED, is different
from either of these.
The decoded information keeps track of data type
duplications. This is important for distinguishing between
a predefined data type and a duplicate of a predefined
data type. The former is a constant object that cannot be
freed; the latter is a derived data type that can be
freed.
The actual arguments used in the creation call for a data
type can be obtained from the MPI_Type_get_contents call.
SEE ALSO
MPI_File_open(3), MPI_Type_get_contents(3)
Man(1) output converted with
man2html