Fixes #3493: Handle the case where rankfile provides the allocation v1.6
authorjsquyres
Sat Feb 09 15:04:49 2013 +0000 (4 months ago)
branchv1.6
changeset 213784a94d8d41e95
parent 21377 7b854048599e
child 21382 c4199091d1fa
Fixes #3493: Handle the case where rankfile provides the allocation

Custom patch from ticket.
NEWS
orte/mca/rmaps/base/rmaps_base_support_fns.c
     1.1 --- a/NEWS	Sat Feb 09 15:01:11 2013 +0000
     1.2 +++ b/NEWS	Sat Feb 09 15:04:49 2013 +0000
     1.3 @@ -50,6 +50,9 @@
     1.4  1.6.4
     1.5  -----
     1.6  
     1.7 +- Fix to obtaining the correct available nodes when a rankfile is
     1.8 +  providing the allocation.  Thanks to Siegmar Gross for reporting the
     1.9 +  problem.
    1.10  - Fix process binding issue on Solaris.  Thanks to Siegmar Gross for
    1.11    reporting the problem.
    1.12  - Updates for MXM 2.0.
     2.1 --- a/orte/mca/rmaps/base/rmaps_base_support_fns.c	Sat Feb 09 15:01:11 2013 +0000
     2.2 +++ b/orte/mca/rmaps/base/rmaps_base_support_fns.c	Sat Feb 09 15:04:49 2013 +0000
     2.3 @@ -83,6 +83,24 @@
     2.4                  ORTE_ERROR_LOG(rc);
     2.5                  return rc;
     2.6              }
     2.7 +        } else if (NULL != orte_rankfile) {
     2.8 +            /* use the rankfile, if provided */
     2.9 +            OPAL_OUTPUT_VERBOSE((5, orte_rmaps_base.rmaps_output,
    2.10 +                                 "%s using rankfile %s",
    2.11 +                                 ORTE_NAME_PRINT(ORTE_PROC_MY_NAME),
    2.12 +                                 orte_rankfile));
    2.13 +            if (ORTE_SUCCESS != (rc = orte_util_add_hostfile_nodes(&nodes, &ignore,
    2.14 +                                                                   orte_rankfile))) {
    2.15 +                ORTE_ERROR_LOG(rc);
    2.16 +                return rc;
    2.17 +            }
    2.18 +            if (0 == opal_list_get_size(&nodes)) {
    2.19 +                OPAL_OUTPUT_VERBOSE((5, orte_rmaps_base.rmaps_output,
    2.20 +                                     "%s nothing found in given rankfile",
    2.21 +                                     ORTE_NAME_PRINT(ORTE_PROC_MY_NAME)));
    2.22 +                OBJ_DESTRUCT(&nodes);
    2.23 +                return ORTE_ERR_BAD_PARAM;
    2.24 +            }
    2.25          } else if (NULL != orte_default_hostfile) {
    2.26              /* fall back to the default hostfile, if provided */
    2.27              OPAL_OUTPUT_VERBOSE((5, orte_rmaps_base.rmaps_output,