Skip to content
Merged
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
20 changes: 18 additions & 2 deletions src/mca/rmaps/seq/rmaps_seq.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ static int prte_rmaps_seq_map(prte_job_t *jdata)
prte_list_item_t *item;
prte_node_t *node, *nd;
seq_node_t *sq, *save = NULL, *seq;
;
pmix_rank_t vpid;
int32_t num_nodes;
int rc;
Expand Down Expand Up @@ -488,7 +487,7 @@ static int process_file(char *path, prte_list_t *list)
char *hstname = NULL;
FILE *fp;
seq_node_t *sq;
char *sep, *eptr;
char *sep, *eptr, *membind_opt;

/* open the file */
fp = fopen(path, "r");
Expand Down Expand Up @@ -517,6 +516,23 @@ static int process_file(char *path, prte_list_t *list)
eptr--;
}
*(eptr + 1) = 0;
/*
* If the submitted LSF job has memory binding related resource requirement, after
* the cpu id list there are memory binding options.
*
* The following is the format of LSB_AFFINITY_HOSTFILE file:
*
* Host1 0,1,2,3 0 2
* Host1 4,5,6,7 1 2
*
* Each line includes: host_name, cpu_id_list, NUMA_node_id_list, and memory_policy.
* In this fix we will drop the last two sections (NUMA_node_id_list and memory_policy)
* of each line and keep them in 'membind_opt' for future use.
*/
if (NULL != (membind_opt = strchr(sep, ' '))) {
*membind_opt = '\0';
membind_opt++;
}
sq->cpuset = strdup(sep);
}

Expand Down