update PMI RTE component to adapt to ORTE changes
This commit was SVN r28885.
Этот коммит содержится в:
родитель
d984d25da3
Коммит
5bfd980968
@ -82,6 +82,7 @@ struct ompi_process_info_t {
|
||||
pid_t pid;
|
||||
ompi_vpid_t num_procs;
|
||||
ompi_local_rank_t my_local_rank;
|
||||
ompi_node_rank_t my_node_rank;
|
||||
ompi_node_rank_t num_local_peers;
|
||||
char *my_hnp_uri;
|
||||
int peer_modex;
|
||||
|
@ -13,7 +13,7 @@
|
||||
|
||||
#include <stdio.h>
|
||||
#include <pmi.h>
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
#include <pmi2.h>
|
||||
#endif
|
||||
|
||||
|
@ -15,7 +15,7 @@
|
||||
#include <unistd.h>
|
||||
#include <stdio.h>
|
||||
#include <pmi.h>
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
#include <pmi2.h>
|
||||
#endif
|
||||
|
||||
@ -72,7 +72,7 @@ ompi_rte_init(int *argc, char ***argv)
|
||||
hwloc_cpuset_t boundset, rootset;
|
||||
char *tmp_str;
|
||||
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
{
|
||||
int spawned, appnum;
|
||||
|
||||
@ -120,6 +120,7 @@ ompi_rte_init(int *argc, char ***argv)
|
||||
for (i = 0 ; i < ompi_process_info.num_local_peers ; ++i) {
|
||||
if (rank == node_ranks[i]) {
|
||||
ompi_process_info.my_local_rank = i;
|
||||
ompi_process_info.my_node_rank = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -13,7 +13,7 @@
|
||||
|
||||
#include <stdio.h>
|
||||
#include <pmi.h>
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
#include <pmi2.h>
|
||||
#endif
|
||||
|
||||
@ -64,7 +64,7 @@ OBJ_CLASS_INSTANCE(local_data_t,
|
||||
*/
|
||||
static int kvs_put(const char *key, const char *value)
|
||||
{
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
return PMI2_KVS_Put(key, value);
|
||||
#else
|
||||
return PMI_KVS_Put(pmi_kvs_name, key, value);
|
||||
@ -73,7 +73,7 @@ static int kvs_put(const char *key, const char *value)
|
||||
|
||||
static int kvs_get(const char *key, char *value, int valuelen)
|
||||
{
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
int len;
|
||||
|
||||
return PMI2_KVS_Get(pmi_kvs_name, PMI2_ID_NULL, key, value, valuelen, &len);
|
||||
@ -87,7 +87,7 @@ static int setup_pmi(void)
|
||||
{
|
||||
int max_length, rc;
|
||||
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
pmi_vallen_max = PMI2_MAX_VALLEN;
|
||||
#else
|
||||
rc = PMI_KVS_Get_value_length_max(&pmi_vallen_max);
|
||||
@ -96,7 +96,7 @@ static int setup_pmi(void)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
/* TODO -- is this ok */
|
||||
max_length = 1024;
|
||||
#else
|
||||
@ -109,7 +109,7 @@ static int setup_pmi(void)
|
||||
return OMPI_ERR_OUT_OF_RESOURCE;
|
||||
}
|
||||
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
rc = PMI2_Job_GetId(pmi_kvs_name, max_length);
|
||||
#else
|
||||
rc = PMI_KVS_Get_my_name(pmi_kvs_name,max_length);
|
||||
@ -118,7 +118,7 @@ static int setup_pmi(void)
|
||||
return OMPI_ERROR;
|
||||
}
|
||||
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
pmi_keylen_max = PMI2_MAX_KEYLEN;
|
||||
#else
|
||||
if (PMI_SUCCESS != (rc = PMI_KVS_Get_key_length_max(&pmi_keylen_max))) {
|
||||
|
@ -14,7 +14,7 @@
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
#include <pmi.h>
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
#include <pmi2.h>
|
||||
#endif
|
||||
|
||||
|
@ -13,7 +13,7 @@
|
||||
|
||||
#include <stdio.h>
|
||||
#include <pmi.h>
|
||||
#if WANT_CRAY_PMI2_EXT
|
||||
#if WANT_PMI2_SUPPORT
|
||||
#include <pmi2.h>
|
||||
#endif
|
||||
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user