Skip to content

Commit

Permalink
Upgrade to MPI_THREAD_SERIALIZED
Browse files Browse the repository at this point in the history
  • Loading branch information
oschuett committed Jun 26, 2021
1 parent c847329 commit 41436c4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@ partially depending on installed libraries (see 2.)
Features useful to deal with legacy systems

- `-D__NO_MPI_THREAD_SUPPORT_CHECK` - Workaround for MPI libraries that do not
declare they are thread safe (funneled).
declare they are thread safe (serialized).
- `-D__NO_IPI_DRIVER` disables the socket interface in case of troubles compiling
on systems that do not support POSIX sockets.
- `-D__HAS_IEEE_EXCEPTIONS` disables trapping temporarily for libraries like scalapack.
Expand Down
10 changes: 5 additions & 5 deletions src/mpiwrap/message_passing.F
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ MODULE message_passing
! USE mpi, ONLY: MPI_DOUBLE_PRECISION, MPI_DOUBLE_COMPLEX, MPI_REAL, MPI_COMPLEX, MPI_ANY_TAG,&
! MPI_ANY_SOURCE, MPI_COMM_NULL, MPI_REQUEST_NULL, MPI_WIN_NULL, MPI_STATUS_SIZE, MPI_STATUS_IGNORE, MPI_STATUSES_IGNORE, &
! MPI_ADDRESS_KIND, MPI_OFFSET_KIND, MPI_MODE_CREATE, MPI_MODE_RDONLY, MPI_MODE_WRONLY,&
! MPI_MODE_RDWR, MPI_MODE_EXCL, MPI_COMM_SELF, MPI_COMM_WORLD, MPI_THREAD_FUNNELED,&
! MPI_MODE_RDWR, MPI_MODE_EXCL, MPI_COMM_SELF, MPI_COMM_WORLD, MPI_THREAD_SERIALIZED,&
! MPI_ERRORS_RETURN, MPI_SUCCESS, MPI_MAX_PROCESSOR_NAME, MPI_MAX_ERROR_STRING, MPI_IDENT,&
! MPI_UNEQUAL, MPI_MAX, MPI_SUM, MPI_INFO_NULL, MPI_IN_PLACE, MPI_CONGRUENT, MPI_SIMILAR, MPI_MIN, MPI_SOURCE,&
! MPI_TAG, MPI_INTEGER8, MPI_INTEGER, MPI_MAXLOC, MPI_2INTEGER, MPI_MINLOC, MPI_LOGICAL, MPI_2DOUBLE_PRECISION,&
Expand Down Expand Up @@ -738,7 +738,7 @@ SUBROUTINE mp_world_init(mp_comm)
!$ no_threading_support = .TRUE.
#else
! Does the right thing when using OpenMP: requests that the MPI
! library supports funneled mode and verifies that the MPI library
! library supports serialized mode and verifies that the MPI library
! provides that support.
!
! Developers: Only the master thread will ever make calls to the
Expand All @@ -751,10 +751,10 @@ SUBROUTINE mp_world_init(mp_comm)
IF (ierr /= 0) CALL mp_stop(ierr, "mpi_init @ mp_world_init")
!$ ELSE
!$OMP MASTER
!$ CALL mpi_init_thread(MPI_THREAD_FUNNELED, provided_tsl, ierr)
!$ CALL mpi_init_thread(MPI_THREAD_SERIALIZED, provided_tsl, ierr)
!$ IF (ierr /= 0) CALL mp_stop(ierr, "mpi_init_thread @ mp_world_init")
!$ IF (provided_tsl .LT. MPI_THREAD_FUNNELED) THEN
!$ CALL mp_stop(0, "MPI library does not support the requested level of threading (MPI_THREAD_FUNNELED).")
!$ IF (provided_tsl .LT. MPI_THREAD_SERIALIZED) THEN
!$ CALL mp_stop(0, "MPI library does not support the requested level of threading (MPI_THREAD_SERIALIZED).")
!$ ENDIF
!$OMP END MASTER
!$ ENDIF
Expand Down

0 comments on commit 41436c4

Please sign in to comment.