Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions opal/mca/pmix/pmix3x/pmix/VERSION
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ greek=
# command, or with the date (if "git describe" fails) in the form of
# "date<date>".

repo_rev=git36e7e24
repo_rev=gitf0b8151

# If tarball_version is not empty, it is used as the version string in
# the tarball filename, regardless of all other versions listed in
Expand All @@ -44,7 +44,7 @@ tarball_version=

# The date when this release was created

date="Feb 09, 2018"
date="Mar 24, 2018"

# The shared library version of each of PMIx's public libraries.
# These versions are maintained in accordance with the "Library
Expand Down
18 changes: 10 additions & 8 deletions opal/mca/pmix/pmix3x/pmix/config/pmix.m4
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ dnl Copyright (c) 2004-2005 The Regents of the University of California.
dnl All rights reserved.
dnl Copyright (c) 2006-2016 Cisco Systems, Inc. All rights reserved.
dnl Copyright (c) 2007 Sun Microsystems, Inc. All rights reserved.
dnl Copyright (c) 2009 IBM Corporation. All rights reserved.
dnl Copyright (c) 2009-2018 IBM Corporation. All rights reserved.
dnl Copyright (c) 2009 Los Alamos National Security, LLC. All rights
dnl reserved.
dnl Copyright (c) 2009-2011 Oak Ridge National Labs. All rights reserved.
dnl Copyright (c) 2011-2013 NVIDIA Corporation. All rights reserved.
dnl Copyright (c) 2013-2017 Intel, Inc. All rights reserved.
dnl Copyright (c) 2013-2018 Intel, Inc. All rights reserved.
dnl Copyright (c) 2015-2017 Research Organization for Information Science
dnl and Technology (RIST). All rights reserved.
dnl Copyright (c) 2016 Mellanox Technologies, Inc.
Expand Down Expand Up @@ -109,12 +109,6 @@ AC_DEFUN([PMIX_SETUP_CORE],[
AC_DEFINE_UNQUOTED([PMIX_MINOR_VERSION], [$PMIX_MINOR_VERSION],
[The library minor version is always available, contrary to VERSION])

pmixmajor=${PMIX_MAJOR_VERSION}L
pmixminor=${PMIX_MINOR_VERSION}L
AC_SUBST(pmixmajor)
AC_SUBST(pmixminor)
AC_CONFIG_FILES(pmix_config_prefix[include/pmix_version.h])

PMIX_RELEASE_VERSION="`$PMIX_top_srcdir/config/pmix_get_version.sh $PMIX_top_srcdir/VERSION --release`"
if test "$?" != "0"; then
AC_MSG_ERROR([Cannot continue])
Expand All @@ -123,6 +117,14 @@ AC_DEFUN([PMIX_SETUP_CORE],[
AC_DEFINE_UNQUOTED([PMIX_RELEASE_VERSION], [$PMIX_RELEASE_VERSION],
[The library release version is always available, contrary to VERSION])

pmixmajor=${PMIX_MAJOR_VERSION}L
pmixminor=${PMIX_MINOR_VERSION}L
pmixrelease=${PMIX_RELEASE_VERSION}L
AC_SUBST(pmixmajor)
AC_SUBST(pmixminor)
AC_SUBST(pmixrelease)
AC_CONFIG_FILES(pmix_config_prefix[include/pmix_version.h])

PMIX_GREEK_VERSION="`$PMIX_top_srcdir/config/pmix_get_version.sh $PMIX_top_srcdir/VERSION --greek`"
if test "$?" != "0"; then
AC_MSG_ERROR([Cannot continue])
Expand Down
6 changes: 6 additions & 0 deletions opal/mca/pmix/pmix3x/pmix/contrib/perf_tools/pmi_intra_perf.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,12 @@ int main(int argc, char **argv)
commit_time, fence_time);
}

/*
* The barrier ensures that all procs finished key fetching
* we had issues with dstor/lockless case evaluation
*/
pmi_fence( 0 );

/* Out of the perf path - send our results to rank 0 using same PMI */
char key[128];
sprintf(key, "PMIX_PERF_get_total_time.%d", rank);
Expand Down
2 changes: 1 addition & 1 deletion opal/mca/pmix/pmix3x/pmix/include/pmix.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013-2017 Intel, Inc. All rights reserved.
* Copyright (c) 2013-2018 Intel, Inc. All rights reserved.
* Copyright (c) 2016 Research Organization for Information Science
* and Technology (RIST). All rights reserved.
*
Expand Down
120 changes: 53 additions & 67 deletions opal/mca/pmix/pmix3x/pmix/include/pmix_common.h.in

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion opal/mca/pmix/pmix3x/pmix/include/pmix_version.h.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
/*
* Copyright (c) 2016 Mellanox Technologies, Inc.
* All rights reserved.
* Copyright (c) 2018 IBM Corporation. All rights reserved.
* $COPYRIGHT$
*
* Additional copyrights may follow
Expand All @@ -15,5 +16,5 @@
/* define PMIx version */
#define PMIX_VERSION_MAJOR @pmixmajor@
#define PMIX_VERSION_MINOR @pmixminor@

#define PMIX_VERSION_RELEASE @pmixrelease@
#endif
2 changes: 1 addition & 1 deletion opal/mca/pmix/pmix3x/pmix/src/class/pmix_hotel.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/*
* Copyright (c) 2012-2016 Cisco Systems, Inc. All rights reserved.
* Copyright (c) 2012 Los Alamos National Security, LLC. All rights reserved
* Copyright (c) 2015-2017 Intel, Inc. All rights reserved.
* Copyright (c) 2015-2018 Intel, Inc. All rights reserved.
* $COPYRIGHT$
*
* Additional copyrights may follow
Expand Down
2 changes: 1 addition & 1 deletion opal/mca/pmix/pmix3x/pmix/src/class/pmix_hotel.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/*
* Copyright (c) 2012-2016 Cisco Systems, Inc. All rights reserved.
* Copyright (c) 2012 Los Alamos National Security, LLC. All rights reserved
* Copyright (c) 2015-2017 Intel, Inc. All rights reserved.
* Copyright (c) 2015-2018 Intel, Inc. All rights reserved.
* $COPYRIGHT$
*
* Additional copyrights may follow
Expand Down
112 changes: 7 additions & 105 deletions opal/mca/pmix/pmix3x/pmix/src/client/pmix_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -1175,135 +1175,37 @@ static void _commitfn(int sd, short args, void *cbdata)
return rc;
}

static void _resolve_peers(int sd, short args, void *cbdata)
{
pmix_cb_t *cb = (pmix_cb_t*)cbdata;
pmix_status_t rc;

cb->status = pmix_preg.resolve_peers(cb->key, cb->pname.nspace,
&cb->procs, &cb->nprocs);
/* post the data so the receiving thread can acquire it */
PMIX_POST_OBJECT(cb);
PMIX_WAKEUP_THREAD(&cb->lock);
}

/* need to thread-shift this request */
PMIX_EXPORT pmix_status_t PMIx_Resolve_peers(const char *nodename,
const char *nspace,
pmix_proc_t **procs, size_t *nprocs)
{
pmix_cb_t *cb;
pmix_status_t rc;
pmix_proc_t proc;

PMIX_ACQUIRE_THREAD(&pmix_global_lock);
if (pmix_globals.init_cntr <= 0) {
PMIX_RELEASE_THREAD(&pmix_global_lock);
return PMIX_ERR_INIT;
}
PMIX_RELEASE_THREAD(&pmix_global_lock);

/* set default */
*procs = NULL;
*nprocs = 0;

cb = PMIX_NEW(pmix_cb_t);
cb->key = (char*)nodename;
cb->pname.nspace = strdup(nspace);

PMIX_THREADSHIFT(cb, _resolve_peers);

/* wait for the result */
PMIX_WAIT_THREAD(&cb->lock);

/* if the nspace wasn't found, then we need to
* ask the server for that info */
if (PMIX_ERR_INVALID_NAMESPACE == cb->status) {
(void)strncpy(proc.nspace, nspace, PMIX_MAX_NSLEN);
proc.rank = PMIX_RANK_WILDCARD;
/* any key will suffice as it will bring down
* the entire data blob */
rc = PMIx_Get(&proc, PMIX_UNIV_SIZE, NULL, 0, NULL);
if (PMIX_SUCCESS != rc) {
PMIX_RELEASE(cb);
return rc;
}
/* retry the fetch */
cb->lock.active = true;
PMIX_THREADSHIFT(cb, _resolve_peers);
PMIX_WAIT_THREAD(&cb->lock);
}
*procs = cb->procs;
*nprocs = cb->nprocs;

rc = cb->status;
PMIX_RELEASE(cb);
return rc;
}

static void _resolve_nodes(int fd, short args, void *cbdata)
{
pmix_cb_t *cb = (pmix_cb_t*)cbdata;
char *regex, **names;

/* get a regular expression describing the PMIX_NODE_MAP */
cb->status = pmix_preg.resolve_nodes(cb->pname.nspace, &regex);
if (PMIX_SUCCESS == cb->status) {
/* parse it into an argv array of names */
cb->status = pmix_preg.parse_nodes(regex, &names);
if (PMIX_SUCCESS == cb->status) {
/* assemble it into a comma-delimited list */
cb->key = pmix_argv_join(names, ',');
pmix_argv_free(names);
} else {
free(regex);
}
}
/* post the data so the receiving thread can acquire it */
PMIX_POST_OBJECT(cb);
PMIX_WAKEUP_THREAD(&cb->lock);
return pmix_preg.resolve_peers(nodename, nspace, procs, nprocs);
}

/* need to thread-shift this request */
PMIX_EXPORT pmix_status_t PMIx_Resolve_nodes(const char *nspace, char **nodelist)
{
pmix_cb_t *cb;
pmix_status_t rc;
pmix_proc_t proc;

PMIX_ACQUIRE_THREAD(&pmix_global_lock);
if (pmix_globals.init_cntr <= 0) {
PMIX_RELEASE_THREAD(&pmix_global_lock);
return PMIX_ERR_INIT;
}
PMIX_RELEASE_THREAD(&pmix_global_lock);

cb = PMIX_NEW(pmix_cb_t);
cb->pname.nspace = strdup(nspace);

PMIX_THREADSHIFT(cb, _resolve_nodes);

/* wait for the result */
PMIX_WAIT_THREAD(&cb->lock);

/* if the nspace wasn't found, then we need to
* ask the server for that info */
if (PMIX_ERR_INVALID_NAMESPACE == cb->status) {
(void)strncpy(proc.nspace, nspace, PMIX_MAX_NSLEN);
proc.rank = PMIX_RANK_WILDCARD;
/* any key will suffice as it will bring down
* the entire data blob */
rc = PMIx_Get(&proc, PMIX_UNIV_SIZE, NULL, 0, NULL);
if (PMIX_SUCCESS != rc) {
PMIX_RELEASE(cb);
return rc;
}
/* retry the fetch */
cb->lock.active = true;
PMIX_THREADSHIFT(cb, _resolve_nodes);
PMIX_WAIT_THREAD(&cb->lock);
}
/* the string we want is in the key field */
*nodelist = cb->key;
/* set default */
*nodelist = NULL;

rc = cb->status;
PMIX_RELEASE(cb);
return rc;
return pmix_preg.resolve_nodes(nspace, nodelist);
}
3 changes: 0 additions & 3 deletions opal/mca/pmix/pmix3x/pmix/src/common/pmix_query.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ static void query_cbfunc(struct pmix_peer_t *peer,
PMIX_BFROPS_UNPACK(rc, peer, buf, &results->status, &cnt, PMIX_STATUS);
if (PMIX_SUCCESS != rc) {
PMIX_ERROR_LOG(rc);
results->status = rc;
goto complete;
}
if (PMIX_SUCCESS != results->status) {
Expand All @@ -75,7 +74,6 @@ static void query_cbfunc(struct pmix_peer_t *peer,
PMIX_BFROPS_UNPACK(rc, peer, buf, &results->ninfo, &cnt, PMIX_SIZE);
if (PMIX_SUCCESS != rc) {
PMIX_ERROR_LOG(rc);
results->status = rc;
goto complete;
}
if (0 < results->ninfo) {
Expand All @@ -84,7 +82,6 @@ static void query_cbfunc(struct pmix_peer_t *peer,
PMIX_BFROPS_UNPACK(rc, peer, buf, results->info, &cnt, PMIX_INFO);
if (PMIX_SUCCESS != rc) {
PMIX_ERROR_LOG(rc);
results->status = rc;
goto complete;
}
}
Expand Down
4 changes: 0 additions & 4 deletions opal/mca/pmix/pmix3x/pmix/src/common/pmix_strings.c
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,8 @@ PMIX_EXPORT const char* PMIx_Proc_state_string(pmix_proc_state_t state)
return "PROC TERMINATED WITHOUT CALLING PMIx_Finalize";
case PMIX_PROC_STATE_COMM_FAILED:
return "PROC LOST COMMUNICATION";
case PMIX_PROC_STATE_SENSOR_BOUND_EXCEEDED:
return "PROC SENSOR BOUND EXCEEDED";
case PMIX_PROC_STATE_CALLED_ABORT:
return "PROC CALLED PMIx_Abort";
case PMIX_PROC_STATE_HEARTBEAT_FAILED:
return "PROC FAILED TO REPORT HEARTBEAT";
case PMIX_PROC_STATE_MIGRATING:
return "PROC WAITING TO MIGRATE";
case PMIX_PROC_STATE_CANNOT_RESTART:
Expand Down
2 changes: 0 additions & 2 deletions opal/mca/pmix/pmix3x/pmix/src/include/pmix_globals.c
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ static void nscon(pmix_nspace_t *p)
PMIX_CONSTRUCT(&p->epilog.cleanup_dirs, pmix_list_t);
PMIX_CONSTRUCT(&p->epilog.cleanup_files, pmix_list_t);
PMIX_CONSTRUCT(&p->epilog.ignores, pmix_list_t);
PMIX_CONSTRUCT(&p->setup_data, pmix_list_t);
}
static void nsdes(pmix_nspace_t *p)
{
Expand All @@ -126,7 +125,6 @@ static void nsdes(pmix_nspace_t *p)
PMIX_LIST_DESTRUCT(&p->epilog.cleanup_dirs);
PMIX_LIST_DESTRUCT(&p->epilog.cleanup_files);
PMIX_LIST_DESTRUCT(&p->epilog.ignores);
PMIX_LIST_DESTRUCT(&p->setup_data);
}
PMIX_EXPORT PMIX_CLASS_INSTANCE(pmix_nspace_t,
pmix_list_item_t,
Expand Down
2 changes: 0 additions & 2 deletions opal/mca/pmix/pmix3x/pmix/src/include/pmix_globals.h
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,6 @@ typedef struct {
pmix_personality_t compat;
pmix_epilog_t epilog; // things to do upon termination of all local clients
// from this nspace
pmix_list_t setup_data; // list of pmix_kval_t containing info structs having blobs
// for setting up the local node for this nspace/application
} pmix_nspace_t;
PMIX_CLASS_DECLARATION(pmix_nspace_t);

Expand Down
2 changes: 1 addition & 1 deletion opal/mca/pmix/pmix3x/pmix/src/include/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* University of Stuttgart. All rights reserved.
* Copyright (c) 2004-2005 The Regents of the University of California.
* All rights reserved.
* Copyright (c) 2014-2017 Intel, Inc. All rights reserved.
* Copyright (c) 2014-2018 Intel, Inc. All rights reserved.
* Copyright (c) 2015 Mellanox Technologies, Inc.
* All rights reserved.
* $COPYRIGHT$
Expand Down
2 changes: 1 addition & 1 deletion opal/mca/pmix/pmix3x/pmix/src/mca/bfrops/base/base.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* Copyright (c) 2004-2005 The Regents of the University of California.
* All rights reserved.
* Copyright (c) 2012 Los Alamos National Security, Inc. All rights reserved.
* Copyright (c) 2014-2017 Intel, Inc. All rights reserved.
* Copyright (c) 2014-2018 Intel, Inc. All rights reserved.
* Copyright (c) 2015 Research Organization for Information Science
* and Technology (RIST). All rights reserved.
* $COPYRIGHT$
Expand Down
Loading