[BACK]Return to patch-src_mpid_ch3_channels_nemesis_include_mpidi_ch3_impl.h CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / parallel / mpi-ch / patches

File: [cvs.NetBSD.org] / pkgsrc / parallel / mpi-ch / patches / patch-src_mpid_ch3_channels_nemesis_include_mpidi_ch3_impl.h (download)

Revision 1.2, Sat Apr 29 18:18:52 2017 UTC (5 years, 3 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2022Q2-base, pkgsrc-2022Q2, pkgsrc-2022Q1-base, pkgsrc-2022Q1, pkgsrc-2021Q4-base, pkgsrc-2021Q4, pkgsrc-2021Q3-base, pkgsrc-2021Q3, pkgsrc-2021Q2-base, pkgsrc-2021Q2, pkgsrc-2021Q1-base, pkgsrc-2021Q1, pkgsrc-2020Q4-base, pkgsrc-2020Q4, pkgsrc-2020Q3-base, pkgsrc-2020Q3, pkgsrc-2020Q2-base, pkgsrc-2020Q2, pkgsrc-2020Q1-base, pkgsrc-2020Q1, pkgsrc-2019Q4-base, pkgsrc-2019Q4, pkgsrc-2019Q3-base, pkgsrc-2019Q3, pkgsrc-2019Q2-base, pkgsrc-2019Q2, pkgsrc-2019Q1-base, pkgsrc-2019Q1, pkgsrc-2018Q4-base, pkgsrc-2018Q4, pkgsrc-2018Q3-base, pkgsrc-2018Q3, pkgsrc-2018Q2-base, pkgsrc-2018Q2, pkgsrc-2018Q1-base, pkgsrc-2018Q1, pkgsrc-2017Q4-base, pkgsrc-2017Q4, pkgsrc-2017Q3-base, pkgsrc-2017Q3, pkgsrc-2017Q2-base, pkgsrc-2017Q2, HEAD
Changes since 1.1: +8 -8 lines

Changes in 3.2:

* Added support for MPI-3.1 features including nonblocking collective I/O,
  address manipulation routines, thread-safety for MPI initialization,
  pre-init functionality, and new MPI_T routines to look up variables
  by name.

* Fortran 2008 bindings are enabled by default and fully supported.

* Added support for the Mellanox MXM InfiniBand interface.  (thanks
  to Mellanox for the code contribution).

* Added support for the Mellanox HCOLL interface for collectives.
  (thanks to Mellanox for the code contribution).

* Significant stability improvements to the MPICH/portals4
  implementation.

* Completely revamped RMA infrastructure including several
  scalability improvements, performance improvements, and bug fixes.

* Added experimental support for Open Fabrics Interfaces (OFI) version 1.0.0.
  https://github.com/ofiwg/libfabric (thanks to Intel for code contribution)

* The Myrinet MX network module, which had a life cyle from 1.1 till
  3.1.2, has now been deleted.

* Several other minor bug fixes, memory leak fixes, and code cleanup.

$NetBSD: patch-src_mpid_ch3_channels_nemesis_include_mpidi_ch3_impl.h,v 1.2 2017/04/29 18:18:52 adam Exp $

Use pthread_mutexattr_setpshared() only when available.

--- src/mpid/ch3/channels/nemesis/include/mpidi_ch3_impl.h.orig	2015-11-10 02:39:01.000000000 +0000
+++ src/mpid/ch3/channels/nemesis/include/mpidi_ch3_impl.h
@@ -106,6 +106,7 @@ int MPIDI_CH3_SHM_Win_free(MPID_Win **wi
                              "**pthread_unlock %s", strerror(pt_err));                  \
     } while (0)
 
+#ifdef _POSIX_THREAD_PROCESS_SHARED
 #define MPIDI_CH3I_SHM_MUTEX_INIT(win_ptr)                                              \
     do {                                                                                \
         int pt_err;                                                                     \
@@ -124,6 +125,23 @@ int MPIDI_CH3_SHM_Win_free(MPID_Win **wi
         MPIR_ERR_CHKANDJUMP1(pt_err, mpi_errno, MPI_ERR_OTHER, "**pthread_mutex",       \
                              "**pthread_mutex %s", strerror(pt_err));                   \
     } while (0);
+#else
+#define MPIDI_CH3I_SHM_MUTEX_INIT(win_ptr)                                              \
+    do {                                                                                \
+        int pt_err;                                                                     \
+        pthread_mutexattr_t attr;                                                       \
+                                                                                        \
+        pt_err = pthread_mutexattr_init(&attr);                                         \
+        MPIR_ERR_CHKANDJUMP1(pt_err, mpi_errno, MPI_ERR_OTHER, "**pthread_mutex",       \
+                             "**pthread_mutex %s", strerror(pt_err));                   \
+        pt_err = pthread_mutex_init((win_ptr)->shm_mutex, &attr);                       \
+        MPIR_ERR_CHKANDJUMP1(pt_err, mpi_errno, MPI_ERR_OTHER, "**pthread_mutex",       \
+                             "**pthread_mutex %s", strerror(pt_err));                   \
+        pt_err = pthread_mutexattr_destroy(&attr);                                      \
+        MPIR_ERR_CHKANDJUMP1(pt_err, mpi_errno, MPI_ERR_OTHER, "**pthread_mutex",       \
+                             "**pthread_mutex %s", strerror(pt_err));                   \
+    } while (0);
+#endif
 
 #define MPIDI_CH3I_SHM_MUTEX_DESTROY(win_ptr)                                           \
     do {                                                                                \