Skip to content

Commit 7fce2f3

Browse files
ggouaillardetjsquyres
authored andcommitted
update MPI_F08_status type
Make the C MPI_F08_status type definition match the updated mpi_f08 type(MPI_Status) definition. This fix the inconsistency introduced in 98bc7af Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
1 parent 43e3add commit 7fce2f3

File tree

2 files changed

+22
-3
lines changed

2 files changed

+22
-3
lines changed

config/ompi_setup_mpi_fortran.m4

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ dnl Copyright (c) 2006-2008 Sun Microsystems, Inc. All rights reserved.
1515
dnl Copyright (c) 2006-2007 Los Alamos National Security, LLC. All rights
1616
dnl reserved.
1717
dnl Copyright (c) 2009 Oak Ridge National Labs. All rights reserved.
18-
dnl Copyright (c) 2014-2019 Research Organization for Information Science
18+
dnl Copyright (c) 2014-2020 Research Organization for Information Science
1919
dnl and Technology (RIST). All rights reserved.
2020
dnl Copyright (c) 2016 IBM Corporation. All rights reserved.
2121
dnl Copyright (c) 2018 FUJITSU LIMITED. All rights reserved.
@@ -276,6 +276,9 @@ AC_DEFUN([OMPI_SETUP_MPI_FORTRAN],[
276276
OMPI_FORTRAN_STATUS_SIZE=$num_ints
277277
AC_MSG_RESULT([$OMPI_FORTRAN_STATUS_SIZE Fortran INTEGERs])
278278
AC_SUBST(OMPI_FORTRAN_STATUS_SIZE)
279+
AC_DEFINE_UNQUOTED([OMPI_FORTRAN_STATUS_SIZE],
280+
[$OMPI_FORTRAN_STATUS_SIZE],
281+
[The number or Fortran INTEGER in MPI Status])
279282

280283
# Setup for the compilers that don't support ignore TKR functionality
281284
OPAL_UNIQ(OMPI_FORTRAN_IKINDS)

ompi/include/mpi.h.in

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717
* reserved.
1818
* Copyright (c) 2011-2013 INRIA. All rights reserved.
1919
* Copyright (c) 2015 University of Houston. All rights reserved.
20-
* Copyright (c) 2015-2018 Research Organization for Information Science
21-
* and Technology (RIST). All rights reserved.
20+
* Copyright (c) 2015-2020 Research Organization for Information Science
21+
* and Technology (RIST). All rights reserved.
2222
* Copyright (c) 2017-2019 IBM Corporation. All rights reserved.
2323
* Copyright (c) 2018 FUJITSU LIMITED. All rights reserved.
2424
* $COPYRIGHT$
@@ -98,6 +98,9 @@
9898
/* Maximum length of processor names (default is 256) */
9999
#undef OPAL_MAX_PROCESSOR_NAME
100100

101+
/* The number or Fortran INTEGER in MPI Status */
102+
#undef OMPI_FORTRAN_STATUS_SIZE
103+
101104
/* Whether we have FORTRAN LOGICAL*1 or not */
102105
#undef OMPI_HAVE_FORTRAN_LOGICAL1
103106

@@ -432,6 +435,19 @@ struct ompi_status_public_t {
432435
};
433436
typedef struct ompi_status_public_t ompi_status_public_t;
434437

438+
/*
439+
* MPI_F08_status
440+
*/
441+
struct ompi_f08_status_public_t {
442+
/* These fields are publicly defined in the MPI specification.
443+
User applications may freely read from these fields. */
444+
MPI_Fint MPI_SOURCE;
445+
MPI_Fint MPI_TAG;
446+
MPI_Fint MPI_ERROR;
447+
MPI_Fint internal[OMPI_FORTRAN_STATUS_SIZE - 3];
448+
};
449+
typedef struct ompi_f08_status_public_t ompi_f08_status_public_t;
450+
435451
/*
436452
* User typedefs
437453
*/

0 commit comments

Comments
 (0)