Merge remote-tracking branch 'up/master' into master-riscv64

Signed-off-by: David Abdurachmanov <david.abdurachmanov@sifive.com>
This commit is contained in:
David Abdurachmanov 2020-01-16 15:54:22 +02:00
commit 4072d90d42
Signed by: davidlt
GPG Key ID: 8B7F1DA0E2C9FDBB
7 changed files with 205 additions and 136 deletions

3
.gitignore vendored
View File

@ -44,3 +44,6 @@ openmpi-1.4.1-RH.tar.bz2
/openmpi-3.1.4.tar.bz2
/openmpi-4.0.0.tar.bz2
/openmpi-4.0.1.tar.bz2
/openmpi-4.0.2rc1.tar.bz2
/openmpi-4.0.2rc2.tar.bz2
/openmpi-4.0.2.tar.bz2

View File

@ -1,32 +0,0 @@
From 68c88e86f2c8ff515a4c54927077143de13516b9 Mon Sep 17 00:00:00 2001
From: Valentin Petrov <valentinp@mellanox.com>
Date: Tue, 16 Apr 2019 14:04:11 +0300
Subject: [PATCH] OSC/UCX: use correct rkey for atomic_fadd in rget/rput
Signed-off-by: Valentin Petrov <valentinp@mellanox.com>
---
ompi/mca/osc/ucx/osc_ucx_comm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/ompi/mca/osc/ucx/osc_ucx_comm.c b/ompi/mca/osc/ucx/osc_ucx_comm.c
index ec760d4fda3..bc3b7f5e7ed 100644
--- a/ompi/mca/osc/ucx/osc_ucx_comm.c
+++ b/ompi/mca/osc/ucx/osc_ucx_comm.c
@@ -881,7 +881,7 @@ int ompi_osc_ucx_rput(const void *origin_addr, int origin_count,
CHECK_VALID_RKEY(module, target, target_count);
- rkey = (module->win_info_array[target]).rkey;
+ rkey = (module->state_info_array[target]).rkey;
OMPI_OSC_UCX_REQUEST_ALLOC(win, ucx_req);
assert(NULL != ucx_req);
@@ -942,7 +942,7 @@ int ompi_osc_ucx_rget(void *origin_addr, int origin_count,
CHECK_VALID_RKEY(module, target, target_count);
- rkey = (module->win_info_array[target]).rkey;
+ rkey = (module->state_info_array[target]).rkey;
OMPI_OSC_UCX_REQUEST_ALLOC(win, ucx_req);
assert(NULL != ucx_req);

View File

@ -1,34 +0,0 @@
From c6ba949f3a0618e26ce2ef53b052b3d38cbbd0d8 Mon Sep 17 00:00:00 2001
From: Nathan Hjelm <hjelmn@me.com>
Date: Wed, 15 May 2019 12:24:22 -0600
Subject: [PATCH] btl/uct: check for support before disabling UCX memory hooks
Signed-off-by: Nathan Hjelm <hjelmn@me.com>
---
opal/mca/btl/uct/btl_uct_component.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/opal/mca/btl/uct/btl_uct_component.c b/opal/mca/btl/uct/btl_uct_component.c
index 971b31a1d85..830c262325d 100644
--- a/opal/mca/btl/uct/btl_uct_component.c
+++ b/opal/mca/btl/uct/btl_uct_component.c
@@ -17,6 +17,7 @@
* Copyright (c) 2018 Amazon.com, Inc. or its affiliates. All Rights reserved.
* Copyright (c) 2018 Triad National Security, LLC. All rights
* reserved.
+ * Copyright (c) 2019 Google, LLC. All rights reserved.
* $COPYRIGHT$
*
* Additional copyrights may follow
@@ -129,7 +130,10 @@ static int mca_btl_uct_component_open(void)
mca_btl_uct_component.num_contexts_per_module = MCA_BTL_UCT_MAX_WORKERS;
}
- if (mca_btl_uct_component.disable_ucx_memory_hooks) {
+ if (mca_btl_uct_component.disable_ucx_memory_hooks &&
+ ((OPAL_MEMORY_FREE_SUPPORT | OPAL_MEMORY_MUNMAP_SUPPORT) ==
+ ((OPAL_MEMORY_FREE_SUPPORT | OPAL_MEMORY_MUNMAP_SUPPORT) &
+ opal_mem_hooks_support_level()))) {
ucm_set_external_event(UCM_EVENT_VM_UNMAPPED);
opal_mem_hooks_register_release(mca_btl_uct_mem_release_cb, NULL);
}

77
7126.patch Normal file
View File

@ -0,0 +1,77 @@
From ea1355beae918b3acd67d5c0ccc44afbcc5b7ca9 Mon Sep 17 00:00:00 2001
From: Edgar Gabriel <egabriel@central.uh.edu>
Date: Tue, 29 Oct 2019 15:21:22 -0500
Subject: [PATCH] fcoll/two_phase: fix error in calculating aggregators in
32bit mode
In fcoll_two_phase_supprot_fns.c: calculation of the aggregator index
failed for large offsets on 32bit machine, due to improper handling of
64bit offsets.
Fixes Issue #7110
Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
---
.../two_phase/fcoll_two_phase_support_fns.c | 25 +++++++++++--------
1 file changed, 14 insertions(+), 11 deletions(-)
diff --git a/ompi/mca/fcoll/two_phase/fcoll_two_phase_support_fns.c b/ompi/mca/fcoll/two_phase/fcoll_two_phase_support_fns.c
index 777cf08b9ae..69a56f2c6c7 100644
--- a/ompi/mca/fcoll/two_phase/fcoll_two_phase_support_fns.c
+++ b/ompi/mca/fcoll/two_phase/fcoll_two_phase_support_fns.c
@@ -10,7 +10,7 @@
* University of Stuttgart. All rights reserved.
* Copyright (c) 2004-2005 The Regents of the University of California.
* All rights reserved.
- * Copyright (c) 2008-2011 University of Houston. All rights reserved.
+ * Copyright (c) 2008-2019 University of Houston. All rights reserved.
* Copyright (c) 2014-2018 Research Organization for Information Science
* and Technology (RIST). All rights reserved.
* Copyright (c) 2015 Los Alamos National Security, LLC. All rights
@@ -156,23 +156,26 @@ int mca_fcoll_two_phase_calc_aggregator(ompio_file_t *fh,
{
- int rank_index, rank;
+ int rank_index, rank;
OMPI_MPI_OFFSET_TYPE avail_bytes;
-
- rank_index = (int) ((off - min_off + fd_size)/ fd_size - 1);
-
+ long long off_ll = (long long) off;
+ long long min_off_ll = (long long) min_off;
+ long long fd_size_ll = (long long) fd_size;
+ long long rank_index_ll;
+
+ rank_index_ll = (((off_ll - min_off_ll + fd_size_ll)/ fd_size_ll) - 1);
+ rank_index = (int) rank_index_ll;
if (striping_unit > 0){
rank_index = 0;
while (off > fd_end[rank_index]) rank_index++;
}
-
if (rank_index >= num_aggregators || rank_index < 0) {
fprintf(stderr,
- "Error in ompi_io_ompio_calcl_aggregator():");
+ "Error in mca_fcoll_two_phase_calc_aggregator:");
fprintf(stderr,
- "rank_index(%d) >= num_aggregators(%d)fd_size=%lld off=%lld\n",
- rank_index,num_aggregators,fd_size,off);
+ "rank_index(%d) >= num_aggregators(%d) fd_size=%ld off=%ld min_off=%ld striping_unit=%d\n",
+ rank_index, num_aggregators, fd_size, off, min_off, striping_unit);
ompi_mpi_abort(&ompi_mpi_comm_world.comm, 1);
}
@@ -184,9 +187,9 @@ int mca_fcoll_two_phase_calc_aggregator(ompio_file_t *fh,
rank = aggregator_list[rank_index];
- #if 0
+#if 0
printf("rank : %d, rank_index : %d\n",rank, rank_index);
- #endif
+#endif
return rank;
}

View File

@ -6,7 +6,7 @@ conflict mpi
prepend-path PATH @LIBDIR@/bin
prepend-path LD_LIBRARY_PATH @LIBDIR@/lib
prepend-path PKG_CONFIG_PATH @LIBDIR@/lib/pkgconfig
prepend-path MANPATH @MANDIR@
prepend-path MANPATH :@MANDIR@
setenv MPI_BIN @LIBDIR@/bin
setenv MPI_SYSCONFIG @ETCDIR@
setenv MPI_FORTRAN_MOD_DIR @FMODDIR@

View File

@ -19,75 +19,82 @@
%global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)
%if 0%{?fedora} >= 32
%bcond_with python2
%else
%bcond_without python2
%endif
%ifarch aarch64 ppc64le x86_64
%bcond_without ucx
%else
%bcond_with ucx
%endif
Name: openmpi%{?_cc_name_suffix}
Version: 4.0.1
Release: 8.0.riscv64%{?dist}
Summary: Open Message Passing Interface
License: BSD and MIT and Romio
URL: http://www.open-mpi.org/
# We can't use %{name} here because of _cc_name_suffix
Source0: https://www.open-mpi.org/software/ompi/v4.0/downloads/openmpi-%{version}.tar.bz2
Source1: openmpi.module.in
Source2: openmpi.pth.py2
Source3: openmpi.pth.py3
Source4: macros.openmpi
# Fix for UCX usage with BTL/UCT
Patch0: https://patch-diff.githubusercontent.com/raw/open-mpi/ompi/pull/6668.patch
# OSC/UCX: use correct rkey for atomic_fadd in rget/rput
Patch1: https://patch-diff.githubusercontent.com/raw/open-mpi/ompi/pull/6594.patch
# Add support for riscv64
Patch10: openmpi-4.0.1-riscv64.patch
BuildRequires: gcc-c++
BuildRequires: gcc-gfortran
%ifarch %{valgrind_arches}
BuildRequires: valgrind-devel
# ARM 32-bit is not supported by rdma
# https://bugzilla.redhat.com/show_bug.cgi?id=1780584
%ifarch %{arm}
%bcond_with rdma
%else
%bcond_without rdma
%endif
%ifnarch %{arm}
BuildRequires: opensm-devel > 3.3.0
Name: openmpi%{?_cc_name_suffix}
Version: 4.0.2
Release: 4.0.riscv64%{?dist}
Summary: Open Message Passing Interface
License: BSD and MIT and Romio
URL: http://www.open-mpi.org/
# We can't use %%{name} here because of _cc_name_suffix
Source0: https://www.open-mpi.org/software/ompi/v4.0/downloads/openmpi-%{version}.tar.bz2
Source1: openmpi.module.in
Source2: openmpi.pth.py2
Source3: openmpi.pth.py3
Source4: macros.openmpi
# fcoll/two_phase: fix error in calculating aggregators in 32bit mode
Patch0: https://patch-diff.githubusercontent.com/raw/open-mpi/ompi/pull/7126.patch
BuildRequires: gcc-c++
BuildRequires: gcc-gfortran
BuildRequires: valgrind-devel
%if %{with rdma}
BuildRequires: opensm-devel > 3.3.0
BuildRequires: rdma-core-devel
%endif
BuildRequires: rdma-core-devel
# Doesn't compile:
# vt_dyn.cc:958:28: error: 'class BPatch_basicBlockLoop' has no member named 'getLoopHead'
# loop->getLoopHead()->getStartAddress(), loop_stmts );
#BuildRequires: dyninst-devel
BuildRequires: hwloc-devel
#BuildRequires: dyninst-devel
BuildRequires: hwloc-devel
# So configure can find lstopo
BuildRequires: hwloc-gui
BuildRequires: java-devel
BuildRequires: hwloc-gui
BuildRequires: java-devel
# Old libevent causes issues
%if !0%{?el7}
BuildRequires: libevent-devel
BuildRequires: libevent-devel
%endif
BuildRequires: libfabric-devel
BuildRequires: libfabric-devel
%ifnarch s390 s390x
BuildRequires: papi-devel
BuildRequires: papi-devel
%endif
BuildRequires: orangefs-devel
BuildRequires: perl-generators
BuildRequires: perl(Getopt::Long)
BuildRequires: pmix-devel
BuildRequires: python2
BuildRequires: python2-devel
BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: orangefs-devel
BuildRequires: perl-generators
BuildRequires: perl-interpreter
BuildRequires: perl(Getopt::Long)
BuildRequires: pmix-devel
BuildRequires: python%{python3_pkgversion}-devel
%ifarch x86_64
BuildRequires: infinipath-psm-devel
BuildRequires: libpsm2-devel
BuildRequires: infinipath-psm-devel
BuildRequires: libpsm2-devel
%endif
%if %{with ucx}
BuildRequires: ucx-devel
BuildRequires: ucx-devel
%endif
BuildRequires: zlib-devel
BuildRequires: zlib-devel
%if !0%{?el7}
BuildRequires: rpm-mpi-hooks
BuildRequires: rpm-mpi-hooks
%endif
BuildRequires: automake
@ -96,15 +103,15 @@ BuildRequires: libtool
BuildRequires: gettext
BuildRequires: perl-interpreter
Provides: mpi
Provides: mpi
%if 0%{?rhel}
# Need this for /etc/profile.d/modules.sh
Requires: environment-modules
Requires: environment-modules
%endif
Requires: environment(modules)
Requires: environment(modules)
# openmpi currently requires ssh to run
# https://svn.open-mpi.org/trac/ompi/ticket/4228
Requires: openssh-clients
Requires: openssh-clients
# Private openmpi libraries
%global __provides_exclude_from %{_libdir}/openmpi/lib/(lib(mca|ompi|open-(pal|rte|trace))|openmpi/).*.so
@ -135,21 +142,21 @@ Requires: (python(abi) = %{python3_version} if python3)
Contains development headers and libraries for openmpi.
%package java
Summary: Java library
Requires: %{name} = %{version}-%{release}
Summary: Java library
Requires: %{name} = %{version}-%{release}
%if 0%{?fedora} >= 20 || 0%{?rhel} >= 7
Requires: java-headless
Requires: java-headless
%else
Requires: java
Requires: java
%endif
%description java
Java library.
%package java-devel
Summary: Java development files for openmpi
Requires: %{name}-java = %{version}-%{release}
Requires: java-devel
Summary: Java development files for openmpi
Requires: %{name}-java = %{version}-%{release}
Requires: java-devel
%description java-devel
Contains development wrapper for compiling Java with openmpi.
@ -158,18 +165,21 @@ Contains development wrapper for compiling Java with openmpi.
# particular package, version, compiler
%global namearch openmpi-%{_arch}%{?_cc_name_suffix}
%if %{with python2}
%package -n python2-openmpi
Summary: OpenMPI support for Python 2
Requires: %{name} = %{version}-%{release}
Requires: python(abi) = %{python2_version}
Summary: OpenMPI support for Python 2
BuildRequires: python2-devel
Requires: %{name} = %{version}-%{release}
Requires: python(abi) = %{python2_version}
%description -n python2-openmpi
OpenMPI support for Python 2.
%endif
%package -n python%{python3_pkgversion}-openmpi
Summary: OpenMPI support for Python 3
Requires: %{name} = %{version}-%{release}
Requires: python(abi) = %{python3_version}
Summary: OpenMPI support for Python 3
Requires: %{name} = %{version}-%{release}
Requires: python(abi) = %{python3_version}
%description -n python%{python3_pkgversion}-openmpi
OpenMPI support for Python 3.
@ -196,9 +206,7 @@ done
--sysconfdir=%{_sysconfdir}/%{namearch} \
--disable-silent-rules \
--enable-builtin-atomics \
%ifnarch %{power64}
--enable-mpi-cxx \
%endif
--enable-mpi-java \
--enable-mpi1-compatibility \
--with-sge \
@ -237,7 +245,11 @@ sed 's#@LIBDIR@#%{_libdir}/%{name}#;
s#@FMODDIR@#%{_fmoddir}/%{name}#;
s#@INCDIR@#%{_includedir}/%{namearch}#;
s#@MANDIR@#%{_mandir}/%{namearch}#;
%if %{with python2}
s#@PY2SITEARCH@#%{python2_sitearch}/%{name}#;
%else
/@PY2SITEARCH@/d;
%endif
s#@PY3SITEARCH@#%{python3_sitearch}/%{name}#;
s#@COMPILER@#openmpi-%{_arch}%{?_cc_name_suffix}#;
s#@SUFFIX@#%{?_cc_name_suffix}_openmpi#' \
@ -266,8 +278,10 @@ sed -i -e s/-ldl// -e s/-lhwloc// \
%{buildroot}%{_libdir}/%{name}/share/openmpi/*-wrapper-data.txt
# install .pth files
%if %{with python2}
mkdir -p %{buildroot}/%{python2_sitearch}/%{name}
install -pDm0644 %{SOURCE2} %{buildroot}/%{python2_sitearch}/openmpi.pth
%endif
mkdir -p %{buildroot}/%{python3_sitearch}/%{name}
install -pDm0644 %{SOURCE3} %{buildroot}/%{python3_sitearch}/openmpi.pth
@ -315,7 +329,9 @@ make check
%dir %{_libdir}/%{name}/share/openmpi
%{_libdir}/%{name}/share/openmpi/amca-param-sets
%{_libdir}/%{name}/share/openmpi/help*.txt
%if %{with rdma}
%{_libdir}/%{name}/share/openmpi/mca-btl-openib-device-params.ini
%endif
%if 0%{?el7}
%{_libdir}/%{name}/share/pmix/
%endif
@ -360,9 +376,11 @@ make check
%{_libdir}/%{name}/share/doc/
%{_mandir}/%{namearch}/man1/mpijavac.1.gz
%if %{with python2}
%files -n python2-openmpi
%dir %{python2_sitearch}/%{name}
%{python2_sitearch}/openmpi.pth
%endif
%files -n python%{python3_pkgversion}-openmpi
%dir %{python3_sitearch}/%{name}
@ -370,11 +388,48 @@ make check
%changelog
* Sun Aug 18 2019 David Abdurachmanov <david.abdurachmanov@sifive.com> - 4.0.1-8.0.riscv64
* Thu Jan 16 2020 David Abdurachmanov <david.abdurachmanov@sifive.com> - 4.0.2-4.0.riscv64
- Add OPAL patch to enable riscv64
- Switch to use %{valgrind_arches}
* Fri Aug 9 2019 Philip Kovacs <pkdevel@yahoo.com> - 4.0.1-8
* Tue Dec 10 2019 Dominik Mierzejewski <rpm@greysector.net> - 4.0.2-4
- disable rdma on ARM 32-bit (bz#1780584)
* Sun Nov 24 2019 Orion Poplawski <orion@nwra.com> - 4.0.2-3
- Add upstream fix for error in calculating aggregators in 32bit mode
* Fri Nov 15 2019 Orion Poplawski <orion@nwra.com> - 4.0.2-2
- Drop python2 for Fedora 32+ (bz#1773125)
* Mon Oct 7 2019 Philip Kovacs <pkfed@fedoraproject.org> - 4.0.2-1
- Update to 4.0.2
* Sat Sep 14 2019 Orion Poplawski <orion@nwra.com> - 4.0.2-0.4.rc2
- Update to 4.0.2rc2
- Re-enable C++ bindings on power64
* Fri Sep 6 2019 Philip Kovacs <pkfed@fedoraproject.org> - 4.0.2-0.3.rc1
- Rebuild for annobin update to correct aarch64 build (bug #1748529)
* Fri Aug 30 2019 Philip Kovacs <pkfed@fedoraproject.org> - 4.0.2-0.2.rc1
- Apply upstream PR 6946 to avoid linking to __mmap
- Add build deps to run upstream autogen.pl
- Remove embedded tabs in the spec
* Thu Aug 29 2019 Philip Kovacs <pkfed@fedoraproject.org> - 4.0.2-0.1.rc1
- Update to 4.0.2rc1
- Closes bug #1746564
* Thu Aug 29 2019 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 4.0.1-11
- Fix MANPATH so normal modules can still be loaded (#1564899)
* Sun Aug 25 2019 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 4.0.1-10
- Rebuilt for hwloc-2.0
* Sun Aug 18 2019 Miro Hrončok <mhroncok@redhat.com> - 4.0.1-9
- Rebuilt for Python 3.8
* Fri Aug 9 2019 Philip Kovacs <pkfed@fedoraproject.org> - 4.0.1-8
- Remove torque support (torque retired: bug #1676147)
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 4.0.1-7

View File

@ -1 +1 @@
SHA512 (openmpi-4.0.1.tar.bz2) = 09f35dc2e44b4f84aab9c5af9d81f90bbdb030e4d90800a5d3ffae88cb32b7faecc9bea0abb113da53c21f73e9d19db68f961f997bc47bdd28d83a87beee0731
SHA512 (openmpi-4.0.2.tar.bz2) = 634d45d989f1e0b8848bfb4eb4527c7edd76d4fccd77a5f8d85a46a5822f97ba653adf13df857c87ae56a8117b4ae2d45ec24249c6ee41a562446d4112ddb770