From b86d4238ca6fc528ec6431bdba5ea9e60cac813a Mon Sep 17 00:00:00 2001 From: Moe Jette <jette1@llnl.gov> Date: Sun, 1 Dec 2002 23:05:11 +0000 Subject: [PATCH] Define new environment variable SLURM_OVERCOMMIT. --- doc/man/man1/srun.1 | 9 ++++++--- src/srun/opt.c | 6 ++++++ 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/doc/man/man1/srun.1 b/doc/man/man1/srun.1 index f33d865a64c..2989976d577 100644 --- a/doc/man/man1/srun.1 +++ b/doc/man/man1/srun.1 @@ -1,6 +1,6 @@ \." $Id$ .\" -.TH SRUN "1" "November 2002" "srun 0.1" "slurm components" +.TH SRUN "1" "December 2002" "srun 0.1" "slurm components" .SH "NAME" srun \- run parallel jobs .SH SYNOPSIS @@ -97,12 +97,12 @@ Specify an alternate distribution method for remote processes. .TP .B block The block method of distribution will allocate processes in-order to -the cpus on a node. This is the default behavior. +the cpus on a node. .TP .B cyclic The cyclic method distributes processes in a round-robin fashion across the allocated nodes. That is, process 1 will be allocated to the first -node, process 2 to the second, and so on. +node, process 2 to the second, and so on. This is the default behavior. .RE .TP \fB\-J\fR, \fB\-\-job\-name\fR=\fIjobname\fR @@ -371,6 +371,9 @@ SLURM_NNODES SLURM_NPROCS \fB\-n, \-\-nprocs\fR=\fIn\fR .TP +SLURM_OVERCOMMIT +\fB\-o, \-\-overcommit\fR +.TP SLURM_PARTITION \fB\-p, --partition\fR=\fIpartition\fR .TP diff --git a/src/srun/opt.c b/src/srun/opt.c index 95d71b6bd33..6411a1e4a2a 100644 --- a/src/srun/opt.c +++ b/src/srun/opt.c @@ -89,6 +89,7 @@ #define OPT_TIME 0x17 #define OPT_THREADS 0x18 #define OPT_WAIT 0x19 +#define OPT_OVERCOMMIT 0x1a /* constraint type options */ #define OPT_MINCPUS 0x50 @@ -262,6 +263,7 @@ env_vars_t env_vars[] = { {"SLURM_NPROCS", OPT_INT, &opt.nprocs, &opt.nprocs_set}, {"SLURM_CPUS_PER_TASK", OPT_INT, &opt.cpus_per_task, &opt.cpus_set}, {"SLURM_NNODES", OPT_INT, &opt.nodes, &opt.nodes_set}, + {"SLURM_OVERCOMMIT", OPT_OVERCOMMIT, NULL, NULL}, {"SLURM_PARTITION", OPT_STRING, &opt.partition, NULL}, {"SLURM_STDINMODE", OPT_INPUT, &opt.input, NULL}, {"SLURM_STDOUTMODE", OPT_OUTPUT, &opt.output, NULL}, @@ -662,6 +664,10 @@ static void _opt_env() } break; + case OPT_OVERCOMMIT: + opt.overcommit = true; + break; + default: /* do nothing */ break; -- GitLab