1
1

Change the datatype MPI_DATATYPE_NULL from NULL to a real datatype delacred

in src/datatype/dt_module.c. Now we can easily test for all the correct
flags on send and receive (like datatype commit ...)

This commit was SVN r1768.
Этот коммит содержится в:
George Bosilca 2004-07-16 21:06:37 +00:00
родитель 568ec6fc68
Коммит c1f0e9bcc2
2 изменённых файлов: 8 добавлений и 2 удалений

Просмотреть файл

@ -273,7 +273,6 @@ enum {
*/ */
#define MPI_GROUP_NULL (&ompi_mpi_group_null) #define MPI_GROUP_NULL (&ompi_mpi_group_null)
#define MPI_COMM_NULL (&ompi_mpi_comm_null) #define MPI_COMM_NULL (&ompi_mpi_comm_null)
#define MPI_DATATYPE_NULL ((MPI_Datatype) 0)
#define MPI_REQUEST_NULL ((MPI_Request) 0) #define MPI_REQUEST_NULL ((MPI_Request) 0)
#define MPI_OP_NULL (&ompi_mpi_op_null) #define MPI_OP_NULL (&ompi_mpi_op_null)
#define MPI_ERRHANDLER_NULL (&ompi_mpi_errhandler_null) #define MPI_ERRHANDLER_NULL (&ompi_mpi_errhandler_null)
@ -336,7 +335,7 @@ extern struct ompi_datatype_t *ompi_mpi_long_double;
extern struct ompi_datatype_t *ompi_mpi_cplex, *ompi_mpi_packed; extern struct ompi_datatype_t *ompi_mpi_cplex, *ompi_mpi_packed;
extern struct ompi_datatype_t *ompi_mpi_unsigned_char; extern struct ompi_datatype_t *ompi_mpi_unsigned_char;
extern struct ompi_datatype_t *ompi_mpi_unsigned_short; extern struct ompi_datatype_t *ompi_mpi_unsigned_short;
extern struct ompi_datatype_t *ompi_mpi_unsigned; extern struct ompi_datatype_t *ompi_mpi_unsigned, *ompi_mpi_datatype_null;
extern struct ompi_datatype_t *ompi_mpi_unsigned_long; extern struct ompi_datatype_t *ompi_mpi_unsigned_long;
extern struct ompi_datatype_t *ompi_mpi_ub, *ompi_mpi_lb; extern struct ompi_datatype_t *ompi_mpi_ub, *ompi_mpi_lb;
extern struct ompi_datatype_t *ompi_mpi_float_int, *ompi_mpi_double_int; extern struct ompi_datatype_t *ompi_mpi_float_int, *ompi_mpi_double_int;
@ -382,6 +381,7 @@ extern MPI_Fint *MPI_F_STATUSES_IGNORE;
#define MPI_MINLOC (&ompi_mpi_op_minloc) #define MPI_MINLOC (&ompi_mpi_op_minloc)
#define MPI_REPLACE (&ompi_mpi_op_replace) #define MPI_REPLACE (&ompi_mpi_op_replace)
#define MPI_DATATYPE_NULL (ompi_mpi_datatype_null)
#define MPI_BYTE (ompi_mpi_byte) #define MPI_BYTE (ompi_mpi_byte)
#define MPI_PACKED (ompi_mpi_packed) #define MPI_PACKED (ompi_mpi_packed)
#define MPI_CHAR (ompi_mpi_char) #define MPI_CHAR (ompi_mpi_char)

Просмотреть файл

@ -79,6 +79,12 @@ ompi_datatype_t basicDatatypes[DT_MAX_PREDEFINED] = {
INIT_BASIC_TYPE( DT_UNAVAILABLE, UNAVAILABLE ) INIT_BASIC_TYPE( DT_UNAVAILABLE, UNAVAILABLE )
}; };
static ompi_datatype_t hide_datatype_null =
{ BASEOBJ_DATA, 0, 0, 0, 0,
0, 0, DT_FLAG_BASIC, 0, 1,
((long long)0), EMPTY_DATA(DATATYPE_NULL) };
ompi_datatype_t* ompi_mpi_datatype_null = &hide_datatype_null;
ompi_datatype_t* ompi_mpi_char = basicDatatypes + DT_CHAR; ompi_datatype_t* ompi_mpi_char = basicDatatypes + DT_CHAR;
ompi_datatype_t* ompi_mpi_byte = basicDatatypes + DT_BYTE; ompi_datatype_t* ompi_mpi_byte = basicDatatypes + DT_BYTE;
ompi_datatype_t* ompi_mpi_int = basicDatatypes + DT_INT; ompi_datatype_t* ompi_mpi_int = basicDatatypes + DT_INT;