Skip to content
Snippets Groups Projects
Commit 0023f631 authored by Moe Jette's avatar Moe Jette
Browse files
parent b50230c8
No related branches found
No related tags found
No related merge requests found
...@@ -18,6 +18,7 @@ documents those changes that are of interest to users and admins. ...@@ -18,6 +18,7 @@ documents those changes that are of interest to users and admins.
This fix is needed for MVAPICH2 use. This fix is needed for MVAPICH2 use.
-- Add "-V" options to slurmctld and slurmd to print version number and exit. -- Add "-V" options to slurmctld and slurmd to print version number and exit.
-- Fix scalability bug in sbcast. -- Fix scalability bug in sbcast.
-- Fix bug in cons_res allocation strategy.
* Changes in SLURM 1.1.0 * Changes in SLURM 1.1.0
======================== ========================
......
...@@ -841,17 +841,13 @@ extern int select_p_job_test(struct job_record *job_ptr, bitstr_t * bitmap, ...@@ -841,17 +841,13 @@ extern int select_p_job_test(struct job_record *job_ptr, bitstr_t * bitmap,
} }
for (i = (best_fit_req - 1); for (i = (best_fit_req - 1);
i >= consec_start[best_fit_location]; i--) { i >= consec_start[best_fit_location]; i--) {
int allocated_cpus; int allocated_cpus, avail_cpus;
if ((max_nodes <= 0) if ((max_nodes <= 0)
|| ((rem_nodes <= 0) && (rem_cpus <= 0))) || ((rem_nodes <= 0) && (rem_cpus <= 0)))
break; break;
if (bit_test(bitmap, i)) if (bit_test(bitmap, i))
continue; continue;
bit_set(bitmap, i);
rem_nodes--;
max_nodes--;
allocated_cpus = 0;
if (!test_only) { if (!test_only) {
rc = select_g_get_select_nodeinfo rc = select_g_get_select_nodeinfo
(select_node_ptr[i].node_ptr, (select_node_ptr[i].node_ptr,
...@@ -859,32 +855,37 @@ extern int select_p_job_test(struct job_record *job_ptr, bitstr_t * bitmap, ...@@ -859,32 +855,37 @@ extern int select_p_job_test(struct job_record *job_ptr, bitstr_t * bitmap,
&allocated_cpus); &allocated_cpus);
if (rc != SLURM_SUCCESS) if (rc != SLURM_SUCCESS)
goto cleanup; goto cleanup;
} else {
allocated_cpus = 0;
} }
if (select_fast_schedule) if (select_fast_schedule) {
rem_cpus -= avail_cpus =
select_node_ptr[i].node_ptr-> select_node_ptr[i].node_ptr->
config_ptr->cpus - config_ptr->cpus -
allocated_cpus; allocated_cpus;
else } else {
rem_cpus -= avail_cpus =
select_node_ptr[i].node_ptr-> select_node_ptr[i].node_ptr->
cpus - allocated_cpus; cpus - allocated_cpus;
}
if (avail_cpus <= 0)
continue;
rem_cpus -= avail_cpus;
bit_set(bitmap, i);
rem_nodes--;
max_nodes--;
} }
} else { } else {
for (i = consec_start[best_fit_location]; for (i = consec_start[best_fit_location];
i <= consec_end[best_fit_location]; i++) { i <= consec_end[best_fit_location]; i++) {
int allocated_cpus; int allocated_cpus, avail_cpus;
if ((max_nodes <= 0) if ((max_nodes <= 0)
|| ((rem_nodes <= 0) && (rem_cpus <= 0))) || ((rem_nodes <= 0) && (rem_cpus <= 0)))
break; break;
if (bit_test(bitmap, i)) if (bit_test(bitmap, i))
continue; continue;
bit_set(bitmap, i);
rem_nodes--;
max_nodes--;
allocated_cpus = 0;
if (!test_only) { if (!test_only) {
rc = select_g_get_select_nodeinfo rc = select_g_get_select_nodeinfo
(select_node_ptr[i].node_ptr, (select_node_ptr[i].node_ptr,
...@@ -892,17 +893,26 @@ extern int select_p_job_test(struct job_record *job_ptr, bitstr_t * bitmap, ...@@ -892,17 +893,26 @@ extern int select_p_job_test(struct job_record *job_ptr, bitstr_t * bitmap,
&allocated_cpus); &allocated_cpus);
if (rc != SLURM_SUCCESS) if (rc != SLURM_SUCCESS)
goto cleanup; goto cleanup;
} else {
allocated_cpus = 0;
} }
if (select_fast_schedule) if (select_fast_schedule) {
rem_cpus -= avail_cpus =
select_node_ptr[i].node_ptr-> select_node_ptr[i].node_ptr->
config_ptr->cpus - config_ptr->cpus -
allocated_cpus; allocated_cpus;
else } else {
rem_cpus -= avail_cpus =
select_node_ptr[i].node_ptr-> select_node_ptr[i].node_ptr->
cpus - allocated_cpus; cpus - allocated_cpus;
}
if (avail_cpus <= 0)
continue;
rem_cpus -= avail_cpus;
bit_set(bitmap, i);
rem_nodes--;
max_nodes--;
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment