Skip to content

Commit

Permalink
Convert OMPI MCA params from legacy orte
Browse files Browse the repository at this point in the history
Pickup and convert all "OMPI_MCA_orte_xxx" params
to their PRRTE equivalent. Note that some don't
have a PRRTE equivalent, so those will silently
be ignored as it would be too big a job to try
and detect and warn for them.

Signed-off-by: Ralph Castain <rhc@pmix.org>
  • Loading branch information
rhc54 committed Nov 16, 2023
1 parent 603fc66 commit c3c6a96
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/mca/schizo/ompi/schizo_ompi.c
Original file line number Diff line number Diff line change
Expand Up @@ -1801,7 +1801,15 @@ static bool check_prte_overlap(char *var, char *value)
return true;
} else if (0 == strncmp(var, "reachable_", strlen("reachable_"))) {
// need to convert reachable to prtereachable
pmix_asprintf(&tmp, "PRTE_MCA_prtereachable_%s", &var[strlen("reachable")]);
pmix_asprintf(&tmp, "PRTE_MCA_prtereachable_%s", &var[strlen("reachable_")]);
// set it, but don't overwrite if they already
// have a value in our environment
setenv(tmp, value, false);
free(tmp);
return true;
} else if (0 == strncmp(var, "orte_", strlen("orte_"))) {
// need to convert "orte" to "prte"
pmix_asprintf(&tmp, "PRTE_MCA_prte_%s", &var[strlen("orte_")]);
// set it, but don't overwrite if they already
// have a value in our environment
setenv(tmp, value, false);
Expand Down

0 comments on commit c3c6a96

Please sign in to comment.