Error check in MPI_Type_get_[true_]extent_x()
This is a followup on a previous thread in the old mpich-devel ML (cannot find archives of the old list to link here) related to this ticket http://trac.mpich.org/projects/mpich/ticket/1774 In my original report, I commented that the issue affected MPI_Type_size_x() and MPI_Type_get_[true_]extent_x(). However, ticket 1174 was filed only for handling MPI_Type_size_x(). By looking at the source code currently in master, it seems that MPI_Type_get_[true_]extent_x() are coded to fail with uncommitted user-defined datatypes. I think you are still missing the trivial patch below: diff --git a/src/mpi/datatype/type_get_extent_x.c b/src/mpi/datatype/type_get_extent_x.c index 94ba3a4..72f9db1 100644 --- a/src/mpi/datatype/type_get_extent_x.c +++ b/src/mpi/datatype/type_get_extent_x.c @@ -99,7 +99,6 @@ int MPI_Type_get_extent_x(MPI_Datatype datatype, MPI_Count *lb, MPI_Count *exten MPID_Datatype *datatype_ptr = NULL; MPID_Datatype_get_ptr(datatype, datatype_ptr); MPID_Datatype_valid_ptr(datatype_ptr, mpi_errno); - MPID_Datatype_committed_ptr(datatype_ptr, mpi_errno); } /* TODO more checks may be appropriate (counts, in_place, buffer aliasing, etc) */ diff --git a/src/mpi/datatype/type_get_true_extent_x.c b/src/mpi/datatype/type_get_true_extent_x.c index c7b4f8f..4a6d9a9 100644 --- a/src/mpi/datatype/type_get_true_extent_x.c +++ b/src/mpi/datatype/type_get_true_extent_x.c @@ -99,7 +99,6 @@ int MPI_Type_get_true_extent_x(MPI_Datatype datatype, MPI_Count *true_lb, MPI_Co MPID_Datatype *datatype_ptr = NULL; MPID_Datatype_get_ptr(datatype, datatype_ptr); MPID_Datatype_valid_ptr(datatype_ptr, mpi_errno); - MPID_Datatype_committed_ptr(datatype_ptr, mpi_errno); } /* TODO more checks may be appropriate (counts, in_place, buffer aliasing, etc) */ -- Lisandro Dalcin --------------- CIMEC (UNL/CONICET) Predio CONICET-Santa Fe Colectora RN 168 Km 472, Paraje El Pozo 3000 Santa Fe, Argentina Tel: +54-342-4511594 (ext 1016) Tel/Fax: +54-342-4511169
participants (1)
-
Lisandro Dalcin