1
1
Граф коммитов

10893 Коммитов

Автор SHA1 Сообщение Дата
Todd Kordenbrock
0a637967fa Use the active PML to call add_procs()
ompi_mtl_portals4_get_endpoint() was incorrectly making a direct
call to ompi_mtl_portals4_add_procs().  Instead use the actve PML
to call add_procs().  If add_procs() fails, call ompi_rte_abort()
to terminate the job.

Signed-off-by: Todd Kordenbrock <thkgcode@gmail.com>
2020-06-22 16:56:16 -05:00
Austen Lauria
b5eafdd5e0
Merge pull request #7844 from abouteiller/std/spawnkeys
Some spawn info keys are standard mandated and cannot be deprecated
2020-06-22 14:18:36 -04:00
Jeff Squyres
900994f602
Merge pull request #7849 from jsquyres/pr/ompi-info-tweaks
ompi_info: trim some redundant output
2020-06-22 11:46:26 -04:00
Nathan Hjelm
a3e276fb03
Merge pull request #7829 from devreal/osc-rdma-noncontig-requests
osc rdma: check for outstanding transfers before completing a request
2020-06-22 08:43:29 -06:00
Joseph Schuchart
d9d18acd49 Fix unintended optimizations detected by STACK
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-22 10:32:22 +02:00
Jeff Squyres
1395c025d4 ompi_info: trim some redundant output
- Remove a duplicate "Configure host" output line
- No longer show the OPAL version.  Since OPAL has never separated
  into its own project, its version is always the same as Open MPI.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-06-20 14:17:07 -04:00
Aurelien Bouteiller
37bd4df01d
Beside the mpi-standard mandated keys, do not deprecate keys that
direcly correspond to an `mpiexec` parameter.

Signed-off-by: Aurelien Bouteiller <bouteill@icl.utk.edu>
2020-06-19 11:50:13 -04:00
Joseph Schuchart
d310a20ecb Add missing free calls to mca_topo_treematch_dist_graph_create
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 14:30:07 +02:00
Joseph Schuchart
e23dcca448 Add missing free calls to osc/ucx
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 14:30:07 +02:00
Joseph Schuchart
ede3c0840a Add missing free calls to osc/sm component_select
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 12:33:34 +02:00
Joseph Schuchart
d9b11b29cd Properly free memory in case of error in mca_common_ompio_prepare_to_group
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 12:31:14 +02:00
Joseph Schuchart
ed1ca1a84b Don't free memory escaping mca_common_ompio_prepare_to_group
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 12:30:38 +02:00
Joseph Schuchart
9a60f5b7fb Add missing free calls to ompi_coll_base_reduce_intra_basic_linear
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 12:27:36 +02:00
Joseph Schuchart
8e24c0d532 Add missing free calls to ompi_coll_base_allgather_intra_bruck
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 12:24:56 +02:00
Joseph Schuchart
dfc46180ea Add missing OBJ_RELEASE to ompi_attr_copy_all
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-19 12:21:18 +02:00
Jeff Squyres
47df60717c check_alt_short_float: ensure compiler supports math
Even if the compiler supports an "alternate" short float type (e.g.,
_Float16), check to make sure that the compiler will correctly link
applications that perform mathematical operations on that type.

Carefully choose the mathematical test in the configure check to
ensure the mathematical operation is not removed by compiler
optimization (when setting CFLAGS=-O1 or higher).

Out of the box, clang 6.0.x and 7.0.x will fail to link applications
that try to perform addition (and other mathematical operations) on
_Float16 variables (an additional CLI flag is required to enable
software emulation of _Float16).  If we detect a situation where the
type is supported by a sample program fails to link and the basename
of $CC is "clang", emit a warning and point the user to a relevant
README.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
Signed-off-by: KAWASHIMA Takahiro <t-kawashima@fujitsu.com>
2020-06-17 08:38:42 -07:00
Jeff Squyres
18cfcc8b70 osc/rdma: update supported BTL list
"openib" no longer exists.

"tcp" had a typo.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-06-16 09:11:01 -07:00
Joseph Schuchart
85ed26f2f8 osc rdma: check for outstanding fragments before completing a request
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-06-16 17:45:00 +02:00
Edgar Gabriel
9af19ab205
Merge pull request #7819 from edgargabriel/pr/avg-fview-size
common/ompio: use avg. file view size in the aggregator selection logic
2020-06-16 10:04:31 -05:00
Jeff Squyres
d522c27037 mpi.h.in: Remove //-style comments
Keep all comments in the user-facing mpi.h.in as "old style" C
comments: /* */.  This gives us maximum portability, just on the off
chance that a user's C compiler does not support //-style comments.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-06-15 12:56:51 -07:00
Jeff Squyres
835f8f1834 mpi.h.in: fixups for static assert messages
1. __STDC_VERSION__ isn't necessarily defined (e.g., by C++
   compilers).  So check to make sure it is defined before we actually
   check the value.
2. If we're in C++11 (or later), use static_assert().
3. Split the static assert macro in two macros:
   * THIS_SYMBOL_WAS_REMOVED_IN_MPI30(...): Insert a valid expression
     (i.e., 0, because it's only used with MPI_Datatype values, and
     since MPI_Datatype is a pointer, 0 is a valid RHS expression)
     before invoking the static assert so that we don't get a syntax
     error instead of the actual static assert error.
   * THIS_FUNCTION_WAS_REMOVED_IN_MPI30(...): No need for the valid
     expression; just invoke the assert functionality.

Also remove an errant "\".

Thanks to Constantine Khrulev and Martin Audet for identifying the
issue and suggesting to use C11's static_assert().

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-06-15 12:55:46 -07:00
Edgar Gabriel
4a8a330bba common/ompio: use avg. file view size in the aggregator selection logic
This is a fix  based on a bugreport on github/mailing list from CGNS.
The core of the problem was that different processes entered different branches of
our aggregator selection logic, due to the fact that in some cases processes had
a matching file_view size and contiguous chunk size (thus assuming 1-D distribution),
and some processes did not (thus assuming 2-D distribution). The fix is to calculate
the avg. file view size across all processes and use this value, thus ensuring that
all processes enter the same branch.

Fixes issue #7809

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2020-06-15 09:17:44 -05:00
Eric Badger
35dbc18df5 mtl/ofi: do not repeat fi_cq_read() after events are read
Once any number of events are read, return immediately, rather than
waiting for fi_cq_read() to return FI_EAGAIN or an error. This can
improve observed latency if the user application is in a blocking call
waiting for us to return. Deleting the while loop here also means
ofi_progress_event_count serves as an upper bound for the total number
of events read in a single call (with the while loop we might read far
more, as long as new events continue to arrive).

Signed-off-by: Eric Badger <eric@badgerio.us>
2020-06-11 10:07:37 -07:00
Aurélien Bouteiller
9c22ad84af
Add the MPI_ERRORS_ABORT predefined error handler (conformance with
mpi-next)

Signed-off-by: Aurélien Bouteiller <bouteill@icl.utk.edu>

Ordering must match fortran definition index for errhandlers, and we
don't want to change the old ones.

Signed-off-by: Aurélien Bouteiller <bouteill@icl.utk.edu>
2020-06-10 12:01:24 -04:00
Aurélien Bouteiller
6a3e781d5c
Add ERR_PROC_ABORTED (compliance with mpi-next)
Signed-off-by: Aurélien Bouteiller <bouteill@icl.utk.edu>
2020-06-10 12:01:24 -04:00
Sergey Oblomov
df0f2ac026 OMPI/HCOLL: fixed typo in vars description
Signed-off-by: Sergey Oblomov <sergeyo@mellanox.com>
2020-05-29 20:13:35 +03:00
bosilca
2b1f053345
Merge pull request #7758 from wckzhang/fixdynamic
coll/tuned: Fix dynamic message size for gather and scatter
2020-05-22 14:15:32 -04:00
Michael Heinz
e21c31f54c
Merge pull request #7722 from mwheinz/mwheinz-7721
Add check for PSM2 reference counting to PSM2 MTL #7721
2020-05-19 08:06:41 -04:00
Michael Heinz
f10305a49f Add check for PSM2 reference counting to PSM2 MTL #7721
As discussed, a feature is being added to libpsm2 to correctly handle
the case where the library is opened by multiple OMPI transports in the same
process. (For example, the OFI BTL and the PSM2 MTL).

* Improved error message to indicate required libpsm2 version.

* Adds a test at autogen/configure time for the existence of
  PSM2_LIB_REFCOUNT_CAP.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
Signed-off-by: Michael Heinz <michael.william.heinz@intel.com>
2020-05-18 15:25:22 -04:00
Ralph Castain
4468691eeb
Sync up with PRRTE and cleanup stale code
Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-05-16 14:48:31 -07:00
William Zhang
50823fe9a9 coll/tuned: Fix dynamic message size for gather and scatter
The gather and scatter operations did not use the correct message size
(Only did datatype size * com size). This did not correctly reflect the
total message size and prevents fine tuning within a com size. This
patch multiplies the value by the number of elements sent.

Signed-off-by: William Zhang <wilzhang@amazon.com>
2020-05-14 12:17:52 -07:00
Howard Pritchard
f744668f5f
Merge pull request #7646 from hppritcha/topic/ofi_common_wl
add a common ofi whitelist/blacklist
2020-05-13 06:44:05 -06:00
Michael Heinz
4a5622a436
Merge pull request #7713 from mwheinz/master-7699
PSM2: Call add_procs through PML
2020-05-13 07:59:43 -04:00
Michael Heinz
548060e43f PSM2: Call add_procs through PML
Change ompi_mtl_ofi_get_endpoint() to call the active PML's add_procs()
rather than the OFI MTL add_procs() directly when discovering a new
process during operation.

Functionally, this has no impact in correct operation. However, the
current behavior means that the heterogenous and active PML checks
are not being executed in the dynamic discovery case.

Signed-off-by: Michael Heinz <michael.william.heinz@intel.com>
2020-05-12 12:35:39 -04:00
Howard Pritchard
9f1081a07a add a common ofi whitelist/blacklist
also add common verbose variable.

Note the verbosity thing is a little tricky owing to the way the MCA frameworks and components are registered and
and initialized.  The BTL's are registered/initialized prior to the MTL components even getting registered.

Signed-off-by: Howard Pritchard <howardp@lanl.gov>
2020-05-09 14:50:31 -06:00
Michael Heinz
dbbdb8f2e2
Merge pull request #7621 from jsquyres/pr/remove-osc-pt2pt
Remove OSC pt2pt component
2020-05-08 12:43:57 -04:00
Brian Barrett
0dc2325297
Merge pull request #7641 from dancejic/multi-NIC
Added multi-NIC support to provider selection
2020-05-07 15:24:41 -07:00
Jeff Squyres
9afe58643e
Merge pull request #7600 from jsquyres/pr/mpit-general-docs
MPI_T general docs
2020-05-07 10:11:40 -04:00
Ralph Castain
42b3541242
Update mtl_psm2.c
Track change in PMIx

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-05-06 17:50:45 -07:00
Michael Heinz
c55c9e67f4 PSM2 update to use PRRTE instead of ORTE
Signed-off-by: Michael Heinz <michael.william.heinz@intel.com>
2020-05-06 16:16:27 -04:00
Jeff Squyres
70993e1670 Move "MPI" and "OpenMPI" man pages to section 5
Make the main man page be Open-MPI(5), and set nroff-native aliases
for MPI(5) and OpenMPI(5).

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-05-02 12:45:32 -07:00
Jeff Squyres
7ace873b50 Add MPI_T.5 man page for Open MPI-specific info
Also added infrastructure to have developers write man pages in
Markdown (vs. nroff).  Pandoc >=v1.12 is used to convert those
Markdown files into actual nroff man pages.

Dist tarballs will contain generated nroff man pages; we don't want to
require users to have Pandoc installed.  Anyone who builds Open MPI
from a git clone will need to have Pandoc installed (similar to how we
treat Flex).  You can opt out of Open MPI's Pandoc-generated man pages
by configuring Open MPI with --disable-man-pages.  This will also
disable "make dist" (i.e., "make dist" will error if you configured
with --disable-man-pages).

Also removed the stuff to re-generate man pages.

This commit also:

1. Includes a new man page, written in Markdown
   (ompi/mpi/man/man5/MPI_T.5.md) that contains Open MPI-specific
   information about MPI_T.
2. Includes a converted ompi/mpi/man/man3/MPI_T_init_thread.3.md (from
   MPI_T_init_thread.3in -- i.e., nroff) just to show that Markdown
   can be used throughout the Open MPI code base for man pages.
3. Made the Makefiles in ompi/mpi/man/man?/ be full-fledged
   Makefile.am's (vs. Makefile.extras that are designed to be included
   in ompi/Makefile.am).  It is more convenient to test generation /
   installation of man pages when you can "make" and "make install" in
   their respective directories (vs. doing a build / install for the
   entire ompi project).
4. Removed logic from ompi/Makefile.am that re-generated man pages if
   opal_config.h changes.

Other man pages -- hopefully all of them! -- will be converted to
Markdown over time.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-05-02 12:45:31 -07:00
Yossi Itigin
b61bf9a00a
Merge pull request #7349 from hoopoepg/topic/ucx-new-api-nbx
OPAL/UCX: enabling new API provided by UCX
2020-05-02 14:30:44 +03:00
Ralph Castain
f608575eec
Remove references to numa_rank
Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-05-01 13:32:29 -07:00
Ralph Castain
86709b1c80
Fix PMIx_Fence call signature
Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-05-01 12:27:42 -07:00
Sergey Oblomov
75bda25ddb OPAL/UCX: enabling new API provided by UCX
- added detection of new API into configuration
- added tag_send call implemented using new API
- added MPI_Send/MPI_Isend/MPI_Recv/MPI_Irecv implementations

Signed-off-by: Sergey Oblomov <sergeyo@mellanox.com>
2020-05-01 17:58:29 +03:00
Nikola Dancejic
167d75b42a common/ofi: Added multi-NIC support to provider selection
Adds the capability to select a NIC based on hardware locality.
Creates a list of NICs that share the same cpuset as the process,
then selects the NIC based on the (local rank) % (number of NICs).
If no NICs are available that share the same cpuset, the selection process
will create a list of all available NICs and make a selection based on
(local rank) % (number of NICs)

Signed-off-by: Nikola Dancejic <dancejic@amazon.com>
2020-05-01 01:05:13 +00:00
Ralph Castain
bd29ab0ae9
Update dpm to handle deprecation of MPI_Info keys
Deprecate the current OMPI-specific MPI_Info key definitions for
MPI_Comm_spawn and replace them with their PMIx equivalents. Issue a
deprecation/conversion warning as this is done. Also issue deprecation
warnings for options such as "ompi_non_mpi" that are no longer used.

Handle both cases where the user might pass either the PMIx attribute
name itself (e.g., "PMIX_MAPBY") or the string value of the attribute
(e.g., PMIX_MAPBY, which translates to "pmix.mapby"). This can only be
done for PMIx v4 and above, so protect that code.

Silence a couple of Coverity warnings and add a test along the way.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-04-29 14:56:38 -07:00
Brian Barrett
4f03f44ced
Merge pull request #7582 from dipti-kothari/pml_check
mca/pml: PML check for direct modex
2020-04-27 12:29:11 -07:00
Austen Lauria
2e22a247bb
Merge pull request #7650 from devreal/fix-7617-oscpt2pt-leak
PT2PT osc: don't extra retain datatype
2020-04-24 08:55:28 -04:00
Austen Lauria
9f2f98e3ec
Merge pull request #7651 from devreal/fix-7617-oscrdma-complete_atomic
RDMA osc: remove extra retain on pending_op
2020-04-24 08:55:08 -04:00
Ralph Castain
91be01beb2
Merge pull request #7652 from rhc54/topic/het
Cleanup heterogeneous builds
2020-04-22 16:20:06 -07:00
Ralph Castain
6d29bbfde8
Cleanup heterogeneous builds
Consolidate the ompi_process_info and opal_process_info structs to
remove duplicate storage and conversion issues. Unwind some interweaving
of include files using opal.h. Silence a couple of warnings.

For now, set the arch to local if PMIX_ARCH is not found.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-04-22 12:46:27 -07:00
Dipti Kothari
5418cc56dd mca/pml: PML check for direct modex
For direct modex, all procs publish the selected pml module
and then at add_procs pml module for each proc is checked
against every other proc in the add_proc call.
For full modex, there is no change in functionality. Only Rank0
publishes its selected pml, all other procs in the add_proc call
check their selected pml against Rank0.
If pml's do not match, throw error and exit.

Signed-off-by: Dipti Kothari <dkothar@amazon.com>
2020-04-22 16:25:01 +00:00
Joseph Schuchart
de67ada442 RDMA osc: remove extra retain on pending_op
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-04-21 22:49:48 +02:00
Joseph Schuchart
07d1011afe OSC base: fix typos in documentation
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-04-21 21:53:36 +02:00
Joseph Schuchart
154cf571b6 OSC base: do not retain datatype by default
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-04-21 21:53:10 +02:00
William Zhang
771f9c011d coll/tuned: Add NULL check to prevent segfault
Signed-off-by: William Zhang <wilzhang@amazon.com>

cr https://code.amazon.com/reviews/CR-23837553
2020-04-21 17:53:46 +00:00
William Zhang
50640402ab coll/tuned: Fix typos
Signed-off-by: William Zhang <wilzhang@amazon.com>
2020-04-21 17:39:37 +00:00
Nikola Dancejic
3637443454 adding NUMA_RANK to process metadata
adding PMIX_NUMA_RANK info to process metadata so that the local NUMA
rank can be accessed through the opal_process_info object.

Signed-off-by: Nikola Dancejic <dancejic@amazon.com>
2020-04-20 22:02:47 +00:00
Ralph Castain
6635795911
Fix intercomm operations
The locality for remote procs is not provided as it is only a local
concept. Thus, you must _always_ use modex_recv_optional to ensure you
don't hang waiting for a response until dmodex times out.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-04-15 17:04:22 -07:00
Ralph Castain
de2d69ca24
Fix hetero builds
Add missing variable declaration

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-04-15 08:46:21 -07:00
Jeff Squyres
8999bae25e Remove OSC pt2pt component
Per https://github.com/open-mpi/ompi/wiki/5.0.x-FeatureList, remove
the OSC pt2pt component.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-04-13 12:29:54 -07:00
Jeff Squyres
b2e0957d6f
Merge pull request #7610 from bosilca/topic/fix_MPI_T
Follow the MPI_T guidelines on return errors.
2020-04-12 14:12:32 -04:00
Ralph Castain
a210f8046f
Cleanup ompi/dpm operations
Do some code cleanup in the connect/accept code. Ensure that the OMPI
layer has access to the PMIx identifier for the process. Add macros for
converting PMIx names to/from strings. Cleanup a few of the simple test
programs. Add a little more info to a btl/tcp error message.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-04-08 08:37:25 -07:00
George Bosilca
f4af1848c9
Follow the MPI_T guidelines on return errors.
As indicated in the MPI3.2 document 14.3.10 page 599 line 1, the only
MPI error code possible is MPI_SUCCESS. All other errors must be in the
error class MPI_T_ERR*.
Fix the return of few pvar/cvar function that failed to correctly
convert to an MPI error code.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-04-08 00:02:45 -04:00
Jeff Squyres
9687d5e867 Upgrade all www.open-mpi.org URLs to https
Found a handful of other URLs that weren't https-ized, so I updated
them, too (after verifying that they support https, of course).

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-04-02 10:43:50 -04:00
Yossi Itigin
5dcd1f4e6c
Merge pull request #7575 from yosefe/topic/pml-ucx-fix-usage-of-mca-pml
pml/ucx: Fix usage of mca_pml_base_pml_check_selected()
2020-03-30 20:06:12 +03:00
Nathan Hjelm
160ff188b8
Merge pull request #7169 from hjelmn/fix_what_wg21_calls_our_problem_not_theirs_seriously__in_some_ways_they_are_correct_but_wtf
configure: use -iquote for non-system include paths
2020-03-30 09:22:54 -07:00
Yossi Itigin
124f0c0d1f pml/ucx: Fix usage of mca_pml_base_pml_check_selected()
Pass the correct ompi_proc_t and array length to
mca_pml_base_pml_check_selected() during dynamic modex.

Signed-off-by: Yossi Itigin <yosefe@mellanox.com>
2020-03-29 17:46:45 +03:00
Howard Pritchard
f136a20cae
Merge pull request #6578 from hppritcha/topic/thread_framework2
Implement a MCA framework for threads
2020-03-27 15:55:48 -06:00
Austen Lauria
8a624ab613
Merge pull request #7523 from mkurnosov/fix-bcast-scatterallgather
Fix Bcast scatter_allgather
2020-03-27 14:17:53 -04:00
Shintaro Iwasaki
a7ea0d9bd7 ompi/request: move REQUEST constants from mca/threads to ompi/request
Signed-off-by: Shintaro Iwasaki <siwasaki@anl.gov>
2020-03-27 10:16:04 -06:00
Noah Evans
ee3517427e Add threads framework
Add a framework to support different types of threading models including
user space thread packages such as Qthreads and argobot:

https://github.com/pmodels/argobots

https://github.com/Qthreads/qthreads

The default threading model is pthreads.  Alternate thread models are
specificed at configure time using the --with-threads=X option.

The framework is static.  The theading model to use is selected at
Open MPI configure/build time.

mca/threads: implement Argobots threading layer

config: fix thread configury

- Add double quotations
- Change Argobot to Argobots
config: implement Argobots check

If the poll time is too long, MPI hangs.

This quick fix just sets it to 0, but it is not good for the
Pthreads version. Need to find a good way to abstract it.

Note that even 1 (= 1 millisecond) causes disastrous performance
degradation.

rework threads MCA framework configury

It now works more like the ompi/mca/rte configury,
modulo some edge items that are special for threading package
linking, etc.

qthreads module
some argobots cleanup

Signed-off-by: Noah Evans <noah.evans@gmail.com>
Signed-off-by: Shintaro Iwasaki <siwasaki@anl.gov>
Signed-off-by: Howard Pritchard <howardp@lanl.gov>
2020-03-27 10:15:45 -06:00
Brian Barrett
64d70b3076 ofi: Call add_procs through PML
Change ompi_mtl_ofi_get_endpoint() to call the active PML's
add_procs() rather than the OFI MTL add_procs() directly when
discovering a new process during operation.

Functionally, this has no impact in correct operation.  However,
the current behavior means that the heterogenous and active PML
checks are not being executed in the dynamic discovery case.

Signed-off-by: Brian Barrett <bbarrett@amazon.com>
2020-03-27 06:06:42 -07:00
Ralph Castain
c704ed4cc5
Merge pull request #7554 from rhc54/topic/proc1
ompi_proc_t size reduction: part 1
2020-03-26 13:23:06 -07:00
Ralph Castain
33ab928e1b ompi_proc_t size reduction: part 1
We currently save the hostname of a proc when we create the ompi_proc_t for it. This was originally done because the only method we had for discovering the host of a proc was to include that info in the modex, and we had to therefore store it somewhere proc-local. Obviously, this ccarried a memory penalty for storing all those strings, and so we added a "cutoff" parameter so that we wouldn't collect hostnames above a certain number of procs.

Unfortunately, this still results in an 8-byte/proc memory cost as we have a char* pointer in the opal_proc_t that is contained in the ompi_proc_t so that we can store the hostname of the other procs if we fall below the cutoff. At scale, this can consume a fair amount of memory.

With the switch to relying on PMIx, there is no longer a need to cache the proc hostnames. Using the "optional" feature of PMIx_Get, we restrict the retrieval to be purely proc-local - i.e., we retrieve the info either via shared memory or from within the proc-internal hash storage (depending upon the active PMIx components). Thus, the retrieval of a hostname is purely a local operation involving no communication.

All RM's are required to provide a complete hostname map of all procs at startup. Thus, we have full access to all hostnames without including them in a modex or having to cache them on each proc. This allows us to remove the char* pointer from the opal_proc_t, saving us 8-bytes/proc.

Unfortunately, PMIx_Get does not currently support the return of a static pointer to memory. Thus, even though PMIx has the hostname in its memory, it can only return a malloc'd version of it. I have therefore ensured that the return from opal_get_proc_hostname is consistently malloc'd and free'd wherever used. This shouldn't be a burden as the hostname is only used in one of two circumstances:

(a) in an error message
(b) in a verbose output for debugging purposes

Thus, there should be no performance penalty associated with the malloc/free requirement. PMIx will eventually be returning static pointers, and so we can eventually simplify this method and return a "const char*" - but as noted, this really isn't an issue even today.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-03-23 12:49:44 -07:00
Ralph Castain
9bb06d0077
Merge pull request #7559 from rhc54/topic/fixes
Bunch of fixes plus PMIx/PRRTE updates
2020-03-23 12:49:18 -07:00
Ralph Castain
95dacd2086
Fix singletons and ensure adequate PMIx version
OMPI can only support PMIx v3 and above. PRRTE requires at least PMIx
v4, so protect against the case where OMPI is built against an external
PMIx v3.

Fix check of PMIx_Init return code for singleton operations.

Ensure that the PMIx framework gets properly opened.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-03-23 10:29:42 -07:00
Austen Lauria
ecd20ddcac Revert "Ensure we get our local topology"
Per the devel mailing list, we discussed the need/desirability of this change. Here is the logic behind not including it:

If you call "hwloc_topology_load", then hwloc merrily does its discovery and slams many-core systems. If you call "opal_hwloc_get_topology", then that is fine - it checks if we already have it, tries to get it from PMIx (using shared mem for hwloc 2.x), and only does the discovery if no other method is available.

We previously decided to let those who need the topology call "opal_hwloc_get_topology" to ensure the topo was available so that we don't load it unless someone actually needs it - in the case where it isn't available via PMIx, this avoids paying the startup time and memory footprint penalties for no reason. The function is protected so it will simply return SUCCESS if the topology is already defined.

After discussion, it was decided to stick with that "only setup the topology if someone actually needs it" approach. Hence, we will not blanket init the topology, and the mtl/ofi component will call opal_hwloc_get_topology to ensure the topo has been defined prior to using it.

Signed-off-by: Austen Lauria <awlauria@us.ibm.com>
2020-03-23 11:15:47 -04:00
Austen Lauria
cf5ca14f7a
Merge pull request #7547 from rhc54/topic/hwloc
Ensure we get our local topology
2020-03-23 10:13:02 -04:00
Austen Lauria
391370a05c
Merge pull request #7546 from devreal/egrequest-obj-retain
grequestx: fix racy initialization and premature destruction
2020-03-23 10:12:32 -04:00
Ralph Castain
2979bb2ce8
Update PMIx and PRRTE to reduce mpirun complexity
Use "prte" instead of "prun" for proxy execution of cmds like mpirun.
This avoids the fork/exec-rendezvous complexities and should result in
more reliable operation.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-03-20 13:49:12 -07:00
Ralph Castain
98893a530b
Ensure we get our local topology
Restore missing call to get_topology - others were doing it in their
components as repeated calls just return success, but let's ensure it is
always present.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-03-20 09:28:20 -07:00
Joseph Schuchart
dabdfe7153 grequestx: fix race condition in initialization
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-03-20 14:53:28 +01:00
Joseph Schuchart
4a39a34bab grequestx: retain request object until it is removed from the list
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-03-20 14:52:42 +01:00
Ralph Castain
757621e199
Re-enable stream buffering option
Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-03-18 16:20:57 -07:00
Ralph Castain
6b4fb509e9
Cleanup singleton detection and data retrieval
Extend the PMIx modex recv macros to cover the full set of
immediate/optional combinations. If PMIx_Init cannot reach a server,
then declare the MPI proc to be a singleton.

Provide full support for info values via PMIx

Catch all the values used in the "info" area of OMPI using data
available from PMIx instead of via envars. Update PMIx and PRRTE to sync
with their capabilities.

PMIx
- ensure cleanup of fork/exec children
- fix bug in gds/hash that left app info off of list

PRRTE
- fix multi-app bugs
- port setup_child logic from orte
- OMPI env changes
- set app->first_rank
- ensure common hostname across prun, prte, and pmix
- Fix "nolocal" support

Silence a warning from btl/vader

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-03-16 12:25:28 -07:00
Artem Polyakov
9ffee9859f
Merge pull request #7512 from artpol84/topic/master/timings_update
Topic/master/timings update
2020-03-12 17:37:42 -07:00
Austen Lauria
f973381a46
Merge pull request #7524 from awlauria/update_info_for_prrte
Update two orte specific env's to be more generic
2020-03-12 20:18:42 -04:00
Ralph Castain
c296dada2c
Merge pull request #7525 from rhc54/topic/fence
Correct fence logic in MPI_Init
2020-03-11 16:55:01 -07:00
Ralph Castain
dd623cec34
Correct fence logic in MPI_Init
The fence logic in MPI_Init got messed up somehow such that we were
always executing a fence, which is not desirable. The logic is supposed
to be:

* if async fence is requested and we are not collecting data, then do
not fence at all

* if async fence is requested and we are collecting data, then execute
the fence in the background - wait for completion at the end of MPI_Init.

* if async fence is not requested, then execute a blocking fence at that
point, collecting data as directed. Note that we cannot actually do a
blocking fence as we need to cycle the event library via opal_progress
as the PMIx progress thread is tied to the OMPI event base.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-03-11 09:25:07 -07:00
Austen Lauria
b675a76361 Update two orte specific env's to be more generic.
orte is gone, and we don't want to require other
RM's to either use a prrte specific env, or to
set their own.

OMPI_MCA_orte_ess_num_procs -> OMPI_MCA_num_procs
OMPI_MCA_orte_cpu_type -> OMPI_MCA_cpu_type

See PRRTE PR's:

https://github.com/openpmix/prrte/pull/443
https://github.com/openpmix/prrte/pull/440

Signed-off-by: Austen Lauria <awlauria@us.ibm.com>
2020-03-11 10:09:35 -04:00
Mikhail Kurnosov
66b6b8d34e Fix Bcast scatter_allgather
Signed-off-by: Mikhail Kurnosov <mkurnosov@gmail.com>
2020-03-11 12:47:47 +07:00
Gilles Gouaillardet
69bc2e8372 misc: fix <> vs "" includes throught the ompi codebase
This commit fixes an issue with the include usage in some
ompi source files. These source files are using the <> form
of include when the "" form is correct (as these are internal,
**not** system headers).

Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
Signed-off-by: Nathan Hjelm <hjelmn@google.com>
2020-03-09 21:13:49 -04:00
Artem Polyakov
7c17a38c96 timings: Fix timings when 'prefix' is used
Signed-off-by: Artem Polyakov <artpol84@gmail.com>
2020-03-07 09:36:43 -08:00
Austen Lauria
04a3a28a74 Some memchecker cleanup and others.
- Port memchecker call from a1d502c.
- Remove unused memcheck macro variables.
- Some code readability improvements.
- Remove some stray +1's in dynamic comm cleanup.
- Re-add OPAL_ENABLE_DEBUG macro to osc header.
- Cleanup some printf's, and includes.
- Refactor cleanup of dpm_disconnect_objs.

Signed-off-by: Austen Lauria <awlauria@us.ibm.com>
2020-03-05 16:44:18 -05:00
Gilles Gouaillardet
e2ad184db5 pml/ob1: silence valgrind errors
always define and initialize padding in various structs
when OPAL_ENABLE_DEBUG is set

Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2020-03-05 16:10:43 -05:00
Gilles Gouaillardet
5751dfe91a mpi/c: fix memchecker invokation
Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2020-03-05 16:10:42 -05:00
Gilles Gouaillardet
fc2516457b osc/pt2pt: silence valgrind warnings
explicitly add and initialize padding to keep valgrind happy

Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2020-03-05 16:10:42 -05:00
Gilles Gouaillardet
4d92b5fcd8 memchecker: fix memchecker_call
- fix handling of contiguous datatypes with a non-zero true lower bound
- fix handling of datatypes using block of non contiguous predefined datatypes

Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2020-03-05 16:10:42 -05:00
Gilles Gouaillardet
0db5a15696 ompi/dpm: plug misc memory leaks
Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2020-03-04 14:54:40 -05:00
Harumi Kuno
397cc44aa4 Fix typo in mca_pml_base_pml_check_selected
Addresses issue https://github.com/open-mpi/ompi/issues/7494

Signed-off-by: Harumi Kuno <harumi.kuno@hpe.com>
2020-03-02 22:49:40 -08:00
Ralph Castain
23303eaee3
Merge pull request #7492 from rhc54/topic/sing
Fix singleton operation
2020-02-29 15:15:04 -08:00
Ralph Castain
674134430c
Fix singleton operation
OpenPMIx fills in a variety of info when it detects that we are in
singleton mode. Best way of detecting it is to look for the "singleton"
at the beginning of the returned nspace.

Make the modex recvs optional so we don't bounce up to the server and
then to the host trying to retrieve job-level info that must be given to
us at job start.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-02-29 12:18:30 -08:00
Ralph Castain
4fe9ae329c
Add missing include and remove stale PML
The "yalla" pml no longer exists

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-02-29 11:54:38 -08:00
Ralph Castain
cbbe67eff9
Merge pull request #7487 from bosilca/topic/pml_from_vpid0
Make sure the PML selection is consistent across the world.
2020-02-28 17:19:26 -08:00
bosilca
c4d36859ec
Merge pull request #7228 from devreal/progress-returns
Harmonize return values of progress callbacks
2020-02-28 20:15:37 -05:00
bosilca
806b35157d
Merge pull request #7261 from bosilca/fix/vprotocol
Fix/vprotocol initialization
2020-02-28 20:14:30 -05:00
George Bosilca
21d743393f
Make sure the PML is consistent across the world.
Temporary solution for the PML inconsistency issue discussed in #7475.
This patch address 2 things: first it make the PMIx key optional so that
if we are not in a full modex mode we don't do a direct modex, and
second it get the PML info from the vpid 0 instead of from the local
rank.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-02-28 17:53:48 -05:00
Jeff Squyres
af1ec9a594
Merge pull request #7323 from bosilca/fix/7320
Trap wrong parameters to MPI_Init_thread.
2020-02-27 06:28:44 -05:00
Tsubasa Yanagibashi
b604f1f1fe add a description in MPI_WIN_DETACH man page.
Signed-off-by: Tsubasa Yanagibashi <fj2505dt@aa.jp.fujitsu.com>
2020-02-27 18:19:55 +09:00
Tsubasa Yanagibashi
070d4c15bc update a description in MPI_Request_free man page.
Signed-off-by: Tsubasa Yanagibashi <fj2505dt@aa.jp.fujitsu.com>
2020-02-27 18:17:44 +09:00
Tsubasa Yanagibashi
6c342aef68 fix some typos and spacing in man pages.
Signed-off-by: Tsubasa Yanagibashi <fj2505dt@aa.jp.fujitsu.com>
2020-02-27 18:14:26 +09:00
Jeff Squyres
ba1f016508
Merge pull request #7428 from hjelmn/finally_kill_the_old_cpp_bindings
ompi: remove obsolete c++ bindings
2020-02-26 17:40:25 -05:00
Nathan Hjelm
0b8baa217d ompi: remove obsolete c++ bindings
This commit contains the following changes:

The C++ bindings were removed from the standard in MPI-3.0. This
commit removes the entirety of the C++ bindings as well as the
support configury.

Removes all references to C++ from the man pages. This includes the
bindings themselves, all references to what C++ bindings return,
all not-available comments, and differences between C++ and other
language bindings.

If the user passes --enable-mpi-cxx, --enable-mpi-cxx-seek, or
--enable-cxx-exceptions, print a warning message an abort configure.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
Signed-off-by: Nathan Hjelm <hjelmn@google.com>
2020-02-26 13:04:55 -08:00
raafatfeki
f46cfc120d fs/gpfs: Solve issues while setting GPFS hints
1- Remove the common symbols issue: global variable not initialized. (#7424)
Move the variables to local scope within the set_info function.
2- Remove GPFS hints using datashipping: not used anymore
3- Redirect output stream to corresponding fs framework.

Signed-off-by: raafatfeki <fekiraafat@gmail.com>
2020-02-25 18:14:20 -05:00
raafatfeki
9ba6ab8209 mca/fs: Check the existence of communicator in file query
The communicator might be not existent yet when mca_fs_gpfs_component_file_query() is called.
Therefore, we need to check it first before calling brodcast function.

Signed-off-by: raafatfeki <fekiraafat@gmail.com>
2020-02-25 16:26:46 -05:00
Geoff Paulsen
207b267135
Merge pull request #7455 from rhc54/topic/warn
Silence a bunch of warnings
2020-02-24 08:55:30 -06:00
Geoff Paulsen
6f28a18f4e
Merge pull request #7444 from tjahns/master
Fix incorrect argument in manual page.
2020-02-24 08:40:04 -06:00
Ralph Castain
89f3418c2c
Merge pull request #7459 from rhc54/topic/cid
Fix comm_spawn
2020-02-23 15:29:44 -08:00
Edgar Gabriel
28776c5d95
Merge pull request #7448 from edgargabriel/topic/individual-as-dummy-module
sharedfp/individual: defer error when not being able to open datafile
2020-02-23 16:35:23 -06:00
Ralph Castain
b35b0f7897
Fix comm_spawn
Use the correct data type in the CID exchange

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-02-23 13:51:22 -08:00
Ralph Castain
86de81baca
Silence a bunch of warnings
Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-02-22 13:05:28 -08:00
Ralph Castain
76b9c15825
Remove lingering ORTE references
Wrapper compiler is trying to link in a libopen-rte. Man pages are
setting an ORTE release date.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-02-22 07:59:19 -08:00
Edgar Gabriel
df6e3e503a sharedfp/individual: defer error when not being able to open datafile
This commit changes the behavior of the individual sharedfp component. If
the component cannot create either the datafile or the metadatafile during File_open,
no error is being raised going forward. This allows applications that do not use shared
file pointer operations to continue execution without any issue.

If the user however subsequently calls MPI_File_write_shared or similar operations, an error
will be raised.

Fixes issue #7429

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2020-02-21 12:13:39 -06:00
Ralph Castain
829fd478b3
Create a hack to protect against non-integer jobids
If someone gives us a namespace that doesn't easily translate to an
integer, we have to create a mechanism for working around the
disconnect. PRRTE has been updated to give us a flag so we know we were
"natively" launched. If we don't see it, then fall back to generating a
hash of the nspace as our jobid. We then have to translate back/forth
between nspace and jobid using a lookup table.

Probably not the right long-term solution, but hopefully helps get us
thru for a bit.

Includes update of PRRTE pointer

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-02-21 06:04:55 -08:00
Thomas Jahns
8ecbe1ce97 Fix incorrect argument in manual page.
Signed-off-by: Thomas Jahns <jahns@dkrz.de>
2020-02-21 11:25:38 +01:00
Austen Lauria
dd5991f513
Merge pull request #7204 from devreal/shmwin_contig
Correctly set baseptr in contiguous shared memory window with local size zero
2020-02-20 13:22:40 -05:00
Nathan Hjelm
8ee80d8855 osc/rdma: fix bug in attach for non-debug builds
This commit fixes an issue with non-debug builds where adding an
attachment to the attachment list doesn't actually happen. This
causes all MPI_Win_detach calls to fail. The call was within an
assert which is optimized out in optimized builds.

Signed-off-by: Nathan Hjelm <hjelmn@google.com>
2020-02-18 12:59:46 -08:00
Nathan Hjelm
eeb3d7f845
Merge pull request #7387 from hjelmn/osc_rdma_allow_overlapping_registration_regions_and_return_the_correct_error_code_when_regions_overlap
osc/rdma: modify attach to check for region overlap
2020-02-17 14:26:53 -07:00
Nathan Hjelm
54c8233f4f osc/rdma: bump the default max dynamic attachments to 64
This commit increaes the osc_rdma_max_attach variable from 32
to 64. The new default is kept low due to the small number
of registration resources on some systems (Cray Aries). A
larger max attachement value can be set by the user on other
systems.

Signed-off-by: Nathan Hjelm <hjelmn@google.com>
2020-02-16 17:09:20 -08:00
Nathan Hjelm
6649aef8bd osc/rdma: modify attach to check for region overlap
This commit addresses two issues in osc/rdma:

 1) It is erroneous to attach regions that overlap. This was being
    allowed but the standard does not allow overlapping attachments.

 2) Overlapping registration regions (4k alignment of attachments)
    appear to be allowed. Add attachment bases to the bookeeping
    structure so we can keep better track of what can be detached.

It is possible that the standard did not intend to allow #2. If that
is the case then #2 should fail in the same way as #1. There should
be no technical reason to disallow #2 at this time.

References #7384

Signed-off-by: Nathan Hjelm <hjelmn@google.com>
2020-02-16 17:09:06 -08:00
Ralph Castain
4bdb5a8103
Merge pull request #7402 from rhc54/topic/up3
Resolve the PMIx v3 incompatibility
2020-02-15 06:05:08 -08:00
Ralph Castain
133e8eba22
Resolve the PMIx v3 incompatibility
Fix a couple of spots in OMPI to resolve warnings. The one in comm_cid
in particular may be responsible for some/all of the comm_spawn issues
as it was passing an incorrect pointer to a macro, thus causing memory
corruption.

Update PRRTE and PMIx to deal with v3/v4 differences.

Signed-off-by: Ralph Castain <rhc@pmix.org>
2020-02-14 21:01:10 -08:00
Tsubasa Yanagibashi
a07a83d189 osc/sm: fix typo and minor correction
- fix a typo `alloc_shared_contig` to `alloc_shared_noncontig`
- correct the value of `blocking_fence`

Signed-off-by: Tsubasa Yanagibashi <fj2505dt@aa.jp.fujitsu.com>
2020-02-14 17:52:56 +09:00
Gilles Gouaillardet
174e967dbc
Remove ORTE project
Will be replaced by PRRTE. Ensure that OMPI and OPAL layers build
without reference to ORTE. Setup opal/pmix framework to be static.
Remove support for all PMI-1 and PMI-2 libraries. Add support for
"external" pmix component as well as internal v4 one.

remove orte: misc fixes

 - UCX fixes
 - VPATH issue
 - oshmem fixes
 - remove useless definition
 - Add PRRTE submodule
 - Get autogen.pl to traverse PRRTE submodule
 - Remove stale orcm reference
 - Configure embedded PRRTE
 - Correctly pass the prefix to PRRTE
 - Correctly set the OMPI_WANT_PRRTE am_conditional
 - Move prrte configuration to the end of OMPI's configure.ac
 - Make mpirun a symlink to prun, when available
 - Fix makedist with --no-orte/--no-prrte option
 - Add a `--no-prrte` option which is the same as the legacy
   `--no-orte` option.
 - Remove embedded PMIx tarball. Replace it with new submodule
   pointing to OpenPMIx master repo's master branch
 - Some cleanup in PRRTE integration and add config summary entry
 - Correctly set the hostname
 - Fix locality
 - Fix singleton operations
 - Fix support for "tune" and "am" options

Signed-off-by: Ralph Castain <rhc@pmix.org>
Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
Signed-off-by: Joshua Hursey <jhursey@us.ibm.com>
2020-02-07 18:20:06 -08:00
Jeff Squyres
ab398f4b9a fortran: ensure not to use [AM_]CPPFLAGS
Automake's Fortran compilation rules inexplicably use CPPFLAGS and
AM_CPPFLAGS.  Unfortunately, this can cause problems in some cases
(e.g., picking up already-installed mpi.mod in a system-default
include search path).

So in relevant module-using Fortran compilation Makefile.am's, zero
out CPPFLAGS and AM_CPPFLAGS.

This has a side-effect of requiring that we compile the one .c file in
the F08 library in a new, separate subdirectory (with its own
Makefile.am that does _not_ have CPPFLAGS/AM_CPPFLAGS zeroed out).

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2020-02-03 14:45:32 -08:00
Jeff Squyres
f4a47a5a8e fortran: remove useless CPPFLAGS assignment
These -D's are for C compilation, not Fortran compilation.  Remove
this useless statement.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-02-03 14:45:25 -08:00
Fangrui Song
5609268e90 Make C and Fortran types for MPI sentinels agree in size
Fix the C types for the following:

* MPI_UNWEIGHTED
* MPI_WEIGHTS_EMPTY
* MPI_ARGV_NULL
* MPI_ARGVS_NULL
* MPI_ERRCODES_IGNORE

There is lengthy discussion on
https://github.com/open-mpi/ompi/pull/7210 describing the issue; the
gist of it is that the C and Fortran types for several MPI global
sentenial values should agree (specifically: their sizes must(**)
agree).  We erroneously had several of these array-like sentinel
values be "array-like" values in C.  E.g., MPI_ERRCODES_IGNORE was an
(int *) in C while its corresponding Fortran type was "integer,
dimension(1)".  On a 64 bit platform, this resulted in C expecting the
symbol size to be sizeof(int*)==8 while Fortran expected the symbol
size to be sizeof(INTEGER, DIMENSION(1))==4.

That is incorrect -- the corresponding C type needed to be (int).
Then both C and Fortran expect the size of the symbol to be the same.

(**) NOTE: This code has been wrong for years.  This mismatch of types
typically worked because, due to Fortran's call-by-reference
semantics, Open MPI was comparing the *addresses* of these instances,
not their *types* (or sizes) -- so even if C expected the size of the
symbol to be X and Fortran expected the size of the symbol to be Y
(where X!=Y), all we really checked at run time was that the addresses
of the symbols were the same.  But it caused linker warning messages,
and even caused errors in some cases.

Specifically: due to a GNU ld bug
(https://sourceware.org/bugzilla/show_bug.cgi?id=25236), the 5 common
symbols are incorrectly versioned VER_NDX_LOCAL because their
definitions in Fortran sources have smaller st_size than those in
libmpi.so.

This makes the Fortran library not linkable with lld in distributions
that ship openmpi built with -Wl,--version-script
(https://bugs.llvm.org/show_bug.cgi?id=43748):

  % mpifort -fuse-ld=lld /dev/null
  ld.lld: error: corrupt input file: version definition index 0 for symbol
  mpi_fortran_argv_null_ is out of bounds
  >>> defined in /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi_usempif08.so
  ...

If we fix the C and Fortran symbols to actually be the same size, the
problem goes away and the GNU ld bug does not come into play.

This commit also fixes a minor issue that MPI_UNWEIGHTED and
MPI_WEIGHTS_EMPTY were not declared as Fortran arrays (not fully fixed
by commit 107c0073dd).

Fixes open-mpi/ompi#7209

Signed-off-by: Fangrui Song <i@maskray.me>
Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-02-02 04:20:39 -08:00
George Bosilca
72501f8f9c Consistent return from all progress functions.
This fix ensures that all progress functions return the number of
completed events.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-01-28 20:16:53 +01:00
Joseph Schuchart
2c97187ee0 Harmonize return values of progress callbacks
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2020-01-28 20:15:03 +01:00
Austen Lauria
3c0fa537c2
Merge pull request #7113 from devreal/osc_rdma_cas
RDMA osc: perform CAS in shared memory if possible
2020-01-28 10:59:17 -05:00
Austen Lauria
10f6a77640
Merge pull request #7315 from abouteiller/export/tcp_errors_v2
Handle error cases in TCP BTL (v2)
2020-01-27 17:03:07 -05:00
Aurelien Bouteiller
395fcc4253
Disable inband PML error reporting during MPI Finalize as it interferes with the Finalize process.
Signed-off-by: Aurelien Bouteiller <bouteill@icl.utk.edu>
2020-01-27 13:32:34 -05:00
Austen Lauria
969eb0286c
Merge pull request #6970 from ggouaillardet/topic/cuda_no_orte
coll/cuda: remove unnecessary references to ORTE
2020-01-27 13:12:32 -05:00
Austen Lauria
4f6978466d
Merge pull request #7284 from bosilca/fix/monitoring_registration
Minor cleanup in the monitoring PML.
2020-01-27 13:01:30 -05:00
George Bosilca
ecbd842ca8 Trap wrong parameters to MPI_Init_thread.
Instead of triggering the fault early in the initialization process, do
a serialized initialization and report the error once all the supporting
infrastructure is up and running.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-01-26 23:59:54 -05:00
Jeff Squyres
f16d2903aa
Merge pull request #7328 from DDNStorage/ime_fs_missing_header
fs/ime: fix compilation errors due to missing header inclusion
2020-01-23 14:13:59 -05:00
Sylvain Didelot
01ae0c22b8 fs/ime: fix compilation errors due to missing header inclusion
OpenMPI doesn't compile anymore with IME because the header
file "ompi/mca/fs/base/base.h" needs to be include in every
file where mca_fs_base_get_mpi_err() is used.

Signed-off-by: Sylvain Didelot <sdidelot@ddn.com>
2020-01-22 17:56:55 +01:00
Austen Lauria
df9745a251
Merge pull request #7299 from awlauria/fix_warnings
Fix some compiler warnings.
2020-01-17 11:33:41 -05:00
Jeff Squyres
25931ea8bf
Merge pull request #7200 from cpshereda/master-opal_gethostname-change
Fix unsafe use of gethostname()
2020-01-13 16:07:43 -05:00
Charles Shereda
cbc6feaab2 Created opal_gethostname() as safer gethostname substitute.
The opal_gethostname() function provides a more robust mechanism
to retrieve the hostname than gethostname(), which can return
results that are not null-terminated, and which can vary in its
behavior from system to system.

opal_gethostname() just returns the value in opal_process_info.nodename;
this is populated in opal_init_gethostname() inside opal_init.c.

-Changed all gethostname calls in opal subtree to opal_gethostname
-Changed all gethostname calls in orte subtree to opal_gethostname
-Changed all gethostname calls in ompi subdir to opal_gethostname
-Changed all gethostname calls in oshmem subdir to opal_gethostname
-Changed opal_if.c in test subdir to use opal_gethostname
-Changed opal_init.c to include opal_init_gethostname. This function
 returns an int and directly sets opal_process_info.nodename per
 jsquyres' modifications.

Relates to open-mpi#6801

Signed-off-by: Charles Shereda <cpshereda@lanl.gov>
2020-01-13 08:52:17 -08:00
Robert Wespetal
49128a7adb mtl/ofi: Add workaround for EFA local/remote capabilities bug
Some versions of Libfabric contain a bug in EFA where FI_REMOTE_COMM and
FI_LOCAL_COMM are not advertised. In order to workaround this, we need to call
fi_getinfo() without those capability bits to see if EFA is available first.

Also move around some of the provider include/exclude list logic so we can skip
this workaround if applicable.

Signed-off-by: Robert Wespetal <wesper@amazon.com>
2020-01-13 08:26:01 -08:00
Jeff Squyres
21bc9042e1 mtl/ofi: check for FI_LOCAL_COMM+FI_REMOTE_COMM
Make sure to get an RDM provider that can provide both local and
remote communication.  We need this check because some providers could
be selected via RXD or RXM, but can't provide local communication, for
example.

Add OPAL_CHECK_OFI_VERSION_GE() m4 macro to check that the Libfabric
we're building against is >= a target version.  Use this check in two
places:

1. MTL/OFI: Make sure it is >= v1.5, because the FI_LOCAL_COMM /
   FI_REMOTE_COMM constants were introduced in Libfabric API v1.5.
2. BTL/usnic: It already had similar configury to check for Libfabric
   >= v1.1, but the usnic component was checking for >= v1.3.  So
   update the btl/usnic configury to use the new macro and check for
   >= v1.3.

Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
2020-01-13 08:19:53 -08:00
George Bosilca
05093f9cb1
Minor cleanup in the monitoring PML.
Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-01-13 09:24:00 -05:00
Austen Lauria
b65ec27307 Fix some compiler warnings.
Silence unused variables, incompatible pointer types,
un-initialized variables, and signed/unsigned comparisons.

Signed-off-by: Austen Lauria <awlauria@us.ibm.com>
2020-01-10 13:10:53 -05:00
Jeff Squyres
dd2d7d2866
Merge pull request #7189 from michaellass/fix-dims_create
dims_create: fix calculation of factors for odd squares
2020-01-10 09:47:09 -05:00
bosilca
2d659323b9
Merge pull request #7233 from bosilca/fix/unused_fortran_protected
Remove unused variable.
2020-01-08 08:04:06 -05:00
George Bosilca
7fac7a07ab
allow thread support in the pessimist vprotocol.
Add MCA parameter to allow support for message logging even when the MPI
library is initialized with support for thread multiple.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-01-08 08:00:06 -05:00
George Bosilca
271deed68e
Fix the vprotocol initialization.
Add a comment about the stages in the vprotocols initialization and why
we cant use the threading provided during the PML initialization.
Instead, use the OMPI internal threading status to prevent the use of
message logging in multi-threaded applications.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-01-07 18:06:45 -05:00
George Bosilca
684b91a1bb
We can only specify one single PML as MCA params.
Make sure the MCA parameter for the PML selection only contains a single
value.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2020-01-07 18:06:45 -05:00
Eisuke Kawashima
d26d4e1d63
Fix typo and update URLs (https, redirection) [skip ci]
Signed-off-by: Eisuke Kawashima <e-kwsm@users.noreply.github.com>
2020-01-07 03:52:25 +09:00
Howard Pritchard
b17cd9049f
Merge pull request #7238 from rwespetal/ofi-prov-name-fix
mtl/ofi: ignore case when comparing provider names
2020-01-02 12:23:39 -07:00
Jeff Squyres
8b424c3863
Merge pull request #7232 from bosilca/hjelmn_neighbor_alltoall_fix
Neighbor alltoall fix
2019-12-17 17:24:05 -05:00
Robert Wespetal
9b72e9465d mtl/ofi: ignore case when comparing provider names
Change the provider include and exclude list name comparison check to
ignore case. The UDP provider's name is uppercase and was being selected
despite being in the exclude list.

Signed-off-by: Robert Wespetal <wesper@amazon.com>
2019-12-16 13:05:00 -08:00
George Bosilca
97eb5d0cf2 Remove unused variable.
It got left over during the Fortran rework.

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2019-12-11 16:59:50 -05:00
George Bosilca
86acdee460
Fix the communication ordering for all cartesian neighbor collectives.
This work is rooted in the [MPI Forum issue
153](https://github.com/mpi-forum/mpi-issues/issues/153).

Signed-off-by: George Bosilca <bosilca@icl.utk.edu>
2019-12-11 12:40:38 -05:00
Todd Kordenbrock
1af6dbe277
Merge pull request #7066 from tkordenbrock/topic/master/portals4.fix.flowcontrol.bugs
portals4: fix flow control bugs
2019-12-11 06:31:26 -06:00
Jeff Squyres
73ecece55d
Merge pull request #7211 from mcoil1/pr/fixing-compiler-warnings
Fix a few compiler warnings
2019-12-09 07:26:15 -05:00
Maxwell Coil
52241dbbcd libnbc: fixed uninitialized variable
Squash compiler warning.

Signed-off-by: Maxwell Coil <mcoil@nd.edu>
2019-12-08 14:03:48 -05:00
Maxwell Coil
3ced33c2eb ompi/dpm/dpm.c: Fix uninititalized variable
Squash compiler warning.

Signed-off-by: Maxwell Coil <mcoil@nd.edu>
2019-12-08 14:03:48 -05:00
William Bailey
e2718e0196 fcoll/two_phase: Compiler warning for wrong variable type used
Squash compiler warning. Changed output specifier to match variable type (long int -> long long int).

Signed-off-by: William Bailey <wbailey2@nd.edu>
2019-12-08 13:15:30 -05:00
Maxwell Coil
8c237e2684 romio: Update ADIOI_R_Exchange_data function
Squash compiler warning due to whitespace/brace problems.

The code block from lines 829-839 was improperly indented, which led to
both the code being confusing and a compiler warning. Comparing this code to
the current version in the MPICH repo made it clear that the code was simply
improperly indented. Fixing the indentation both makes the code readable and
squashes the compiler warning.

Signed-off-by: Maxwell Coil <mcoil@nd.edu>
2019-12-05 18:24:02 -05:00
William Bailey
30bda56bce romio: fix uninitialized variable
Squash compiler warning.

ROMIO is third-party software but has an annoying compiler warning;
this is the minimum distance fix.

Signed-off-by: William Bailey <wbailey2@nd.edu>
2019-12-02 17:35:05 -05:00
Gilles Gouaillardet
967cf68027 configury: fix a typo in mpiext/shortfloat
remove an extra and useless comma

Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2019-11-29 11:09:54 +09:00
Joseph Schuchart
06bbcf4fd6 Correctly set baseptr in contiguous shared memory window with local size zero
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2019-11-28 11:04:30 +01:00
raafatfeki
7b2d83c898 mca/fs: Remove unused functions and prototypes & reduce recurent code through all components
I removed the implementation and/or prototypes of all unused functions defined for all components.
To reduce recurrent code, I created functions under base for the management of error codes and setting of file permission and amode.
Then, I replaced these recurrent code by those function for all components.

Signed-off-by: raafatfeki <fekiraafat@gmail.com>

add a missing header file

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2019-11-25 09:01:38 -06:00
raafatfeki
5988297bd8 fs/gpfs: Assign file creation to one process and management of error codes translation.
When O_CREAT and O_EXCL are set, open() shall fail if the file exists. Therefore, I assigned the file creation to the root process only.
I also translated the errno codes to their corresponding MPI error codes.

Signed-off-by: raafatfeki <fekiraafat@gmail.com>
2019-11-25 09:01:38 -06:00
raafatfeki
a2b1a03e7b fs/gpfs: Update component to compile with latest gpfs versions
I updated the gpfs component to match the latest structures and functions definitions and remove compiler wranings.
Disabled mpi info setting for the gpfs option "Data Shipping" since it is no longer supported in the latest gpfs versions.

Signed-off-by: raafatfeki <fekiraafat@gmail.com>
2019-11-25 09:01:38 -06:00
Edgar Gabriel
715a6e8c27 fs/gpfs: update component and module file
to match what we are doing meanwhile in the other fs compomenents.

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2019-11-25 09:01:38 -06:00
Edgar Gabriel
8d31ba3a09 fs/gpfs: update configure logic
update the configure logic of the gpfs component
based on what we learned from user feedback over the last
two years for the other components

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2019-11-25 09:01:38 -06:00
XuanWang1982
cd76e53479 Changed parameter name from siox to gpfs
Adding get_info function for gpfs module
annotate printf information

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2019-11-25 09:01:38 -06:00
Christoph Niethammer
d3c11396fd First code review round of the GPFS module.
Delete check for amode which should go to a higler layer, e.g. ompi_file_open.
Only perform Info value check if key is found.

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2019-11-25 09:01:38 -06:00
XuanWang1982
b1dc58eeb2 First version for GPFS module. To be tested
Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2019-11-25 09:01:38 -06:00
Howard Pritchard
ebf003581b
Merge pull request #7183 from hppritcha/topic/quiet_lustre
lustre: squash some compiler warnings
2019-11-22 19:19:08 -07:00
Barton Chittenden
47816ef83b Remove mxm, yalla and ikrit
Signed-off-by: Barton Chittenden <bartonski@gmail.com>
2019-11-22 13:40:16 -08:00
Michael Lass
67490118ad dims_create: fix calculation of factors for odd squares
Until now sqrt(n) was missed as a factor for odd square numbers n. This
lead to suboptimal results of MPI_Dims_create for input numbers like 9,
25, 49, ... Fix the results by including sqrt(n) in the search for
factors.

Refs: #7186

Signed-off-by: Michael Lass <bevan@bi-co.net>
2019-11-22 20:12:58 +01:00
Edgar Gabriel
ea1355beae 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>
2019-11-22 09:45:19 -06:00
Howard Pritchard
e66a7cef11 lustre: squash some compiler warnings
Compiling OMPI on cray systems using latest Cray compilers (clang based)
yielded some compiler warnings from ompio/lustre.  Squash these warnings.

Signed-off-by: Howard Pritchard <howardp@lanl.gov>
2019-11-21 14:14:40 -06:00
Geoff Paulsen
9e17f028b5
Merge pull request #5507 from markalle/prot_table
Adding -mca comm_method to print table of communication methods
2019-11-14 14:24:06 -06:00
Austen Lauria
edcd6d8aeb
Merge pull request #7146 from bgoglin/master
fix typos hlwoc->hwloc
2019-11-13 15:38:00 -05:00
Yossi Itigin
40e2fbb093
Merge pull request #7114 from brminich/topic/mlx_scat_tuning
COLL/TUNED: Add linear scatter using isend for mlnx platform
2019-11-07 13:38:21 +02:00
Mikhail Brinskii
f2cbd4806e COLL/TUNED: Add linear scatter using isend for mlnx platform
Signed-off-by: Mikhail Brinskii <mikhailb@mellanox.com>
2019-11-07 11:04:39 +02:00
Brice Goglin
5c6bd7ea4e fix typos hlwoc->hwloc
Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>
2019-11-06 10:42:36 +01:00
Mark Allen
6855ebb84b Adding -mca comm_method to print table of communication methods
This is closely related to Platform-MPI's old -prot feature.

The long-format of the tables it prints could look like this:
>   Host 0 [myhost001] ranks 0 - 1
>   Host 1 [myhost002] ranks 2 - 3
>   Host 2 [myhost003] ranks 4
>   Host 3 [myhost004] ranks 5
>   Host 4 [myhost005] ranks 6
>   Host 5 [myhost006] ranks 7
>   Host 6 [myhost007] ranks 8
>   Host 7 [myhost008] ranks 9
>   Host 8 [myhost009] ranks 10
>
>    host | 0    1    2    3    4    5    6    7    8
>   ======|==============================================
>       0 : sm   tcp  tcp  tcp  tcp  tcp  tcp  tcp  tcp
>       1 : tcp  sm   tcp  tcp  tcp  tcp  tcp  tcp  tcp
>       2 : tcp  tcp  self tcp  tcp  tcp  tcp  tcp  tcp
>       3 : tcp  tcp  tcp  self tcp  tcp  tcp  tcp  tcp
>       4 : tcp  tcp  tcp  tcp  self tcp  tcp  tcp  tcp
>       5 : tcp  tcp  tcp  tcp  tcp  self tcp  tcp  tcp
>       6 : tcp  tcp  tcp  tcp  tcp  tcp  self tcp  tcp
>       7 : tcp  tcp  tcp  tcp  tcp  tcp  tcp  self tcp
>       8 : tcp  tcp  tcp  tcp  tcp  tcp  tcp  tcp  self
>
>   Connection summary:
>     on-host:  all connections are sm or self
>     off-host: all connections are tcp

In this example hosts 0 and 1 had multiple ranks so "sm" was more
meaningful than "self" to identify how the ranks on the host are
talking to each other. While host 2..8 were one rank per host so
"self" was more meaningful as their btl.

Above a certain number of hosts (12 by default) the above table gets too big
so we shrink to a more abbreviated looking table that has the same data:
>    host | 0 1 2 3 4       8
>   ======|====================
>       0 : A C C C C C C C C
>       1 : C A C C C C C C C
>       2 : C C B C C C C C C
>       3 : C C C B C C C C C
>       4 : C C C C B C C C C
>       5 : C C C C C B C C C
>       6 : C C C C C C B C C
>       7 : C C C C C C C B C
>       8 : C C C C C C C C B
>   key: A == sm
>   key: B == self
>   key: C == tcp

Then above 36 hosts we stop printing the 2d table entirely and just print the
summary:
>   Connection summary:
>     on-host:  all connections are sm or self
>     off-host: all connections are tcp

The options to control it are
    -mca comm_method 1   :   print the above table at the end of MPI_Init
    -mca comm_method 2   :   print the above table at the beginning of MPI_Finalize
    -mca comm_method_max <n> :  number of hosts <n> for which to print a full size 2d
    -mca comm_method_brief 1 :  only print summary output, no 2d table
    -mca comm_method_fakefile <filename> :  for debugging only

* printing at init vs finalize:

The most important difference between these two is that when printing the table
during MPI_Init(), we send extra messages to make sure all hosts are connected to
each other. So the table ends up working against the idea of on-demand connections
(although it's only forcing the n^2 connections in the number of hosts, not the
total ranks).  If printing at MPI_Finalize() we don't create any connections that
aren't already connected, so the table is more likely to have "n/a" entries if
some hosts never connected to each other.

* how many hosts <n> for which to print a full size 2d table

The option -mca comm_method_max <n> can be used to specify a number of hosts <n>
(default 12) that controls at what host-count the unabbreviated / abbreviated
2d tables get printed:
    1 - n      : full size 2d table
    n+1 - 3n   : shortened 2d table
    3n+1 - inf : summary only, no 2d table

* brief

The option -mca comm_method_brief 1 can be used to skip the printing of the 2d
table and only show the short summary

* fakefile

This is a debugging option that allows easeir testing of all the printout
routines by letting all the detected communication methods between the hosts
be overridden by fake data from a file.

The source of the information used in the table is the .mca_component_name

In the case of BTLs, the module always had a .btl_component linking back to the
component. The vars mca_pml_base_selected_component and ompi_mtl_base_selected_component
offer similar functionality for pml/mtl.

So with the ability to identify the component, we can then access
the component name with code like this
    mca_pml_base_selected_component.pmlm_version.mca_component_name
See the three lookup_{pml,mtl,btl}_name() functions in hook_comm_method_fns.c,
and their use in comm_method() to parse the strings and produce an integer
to represent the connection type being used.

Signed-off-by: Mark Allen <markalle@us.ibm.com>
2019-10-31 16:23:57 -04:00
Gilles Gouaillardet
631a43581f
Merge pull request #7117 from ggouaillardet/topic/f08_bind_c_constants_revamp_misc_fixes
fortran/use-mpi-f08: misc fixes
2019-10-30 10:42:33 +09:00
Edgar Gabriel
ad5d0df4e9 common/ompio: fix calculation in simple-grouping option
This is based on a bug reported on the mailing list using a netcdf testcase.
The problem occurs if processes are using a custom file view, but on some
of them it appears as if the default file view is being used. Because of that,
the simple-grouping option lead to different number of aggregators used on different
processes, and ultimately to a deadlock. This patch fixes the problem by not using
the file_view size anymore for the calculation in the simple-grouping option,
but the contiguous chunk size (which is identical on all processes).

Fixes issue #7109

Signed-off-by: Edgar Gabriel <egabriel@central.uh.edu>
2019-10-29 12:30:41 -05:00
Gilles Gouaillardet
fda4d040da fortran/use-mpi-f08: misc fixes
- fix typos from open-mpi/ompi@b10a60a5a9
 - remove remaining references to OMPI_PROTECTED from open-mpi/ompi@df6d763a53

Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>
2019-10-29 15:00:51 +09:00
Joseph Schuchart
02dd877d8a RDMA osc: perform CAS in shared memory if possible
Signed-off-by: Joseph Schuchart <schuchart@hlrs.de>
2019-10-28 11:24:16 +01:00