Skip to content
Snippets Groups Projects
Commit f5b8c0ec authored by Moe Jette's avatar Moe Jette
Browse files

modify cr logic to only allocate one core per node for a job in overcommit mode

parent 91163b79
No related branches found
No related tags found
No related merge requests found
...@@ -208,12 +208,17 @@ static int _job_assign_tasks(struct select_cr_job *job, ...@@ -208,12 +208,17 @@ static int _job_assign_tasks(struct select_cr_job *job,
/* determine the number of required cores. When multiple threads /* determine the number of required cores. When multiple threads
* are available, the maxtasks value may not reflect the requested * are available, the maxtasks value may not reflect the requested
* core count, which is what we are seeking here. */ * core count, which is what we are seeking here. */
maxcores = maxtasks / usable_threads; if (job->job_ptr->details->overcommit) {
while ((maxcores * usable_threads) < maxtasks) maxcores = 1;
maxcores++; reqcores = 1;
reqcores = mc_ptr->min_cores * mc_ptr->min_sockets; } else {
if (maxcores < reqcores) maxcores = maxtasks / usable_threads;
maxcores = reqcores; while ((maxcores * usable_threads) < maxtasks)
maxcores++;
reqcores = mc_ptr->min_cores * mc_ptr->min_sockets;
if (maxcores < reqcores)
maxcores = reqcores;
}
offset = _find_offset(job, job_index, cores, sockets, maxcores, cr_type, offset = _find_offset(job, job_index, cores, sockets, maxcores, cr_type,
this_cr_node); this_cr_node);
......
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