Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Slurm
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tud-zih-energy
Slurm
Commits
bb12c25b
Commit
bb12c25b
authored
7 years ago
by
Isaac Hartung
Committed by
Danny Auble
7 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix tests to work when
SelectTypeparameters has CR_ONE_TASK_PER_CORE Bug 3797
parent
2e0cee37
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
testsuite/expect/test21.21
+12
-1
12 additions, 1 deletion
testsuite/expect/test21.21
testsuite/expect/test21.30
+31
-0
31 additions, 0 deletions
testsuite/expect/test21.30
with
43 additions
and
1 deletion
testsuite/expect/test21.21
+
12
−
1
View file @
bb12c25b
...
@@ -48,6 +48,7 @@ set timeout 60
...
@@ -48,6 +48,7 @@ set timeout 60
set test_node " "
set test_node " "
# cr_core = 1 / cr_cpu = 0
# cr_core = 1 / cr_cpu = 0
set selectparam 0
set selectparam 0
set one_task_pc 0
# test maxjob maxnode maxsubmit maxwall
# test maxjob maxnode maxsubmit maxwall
array set acct_mod_desc {}
array set acct_mod_desc {}
...
@@ -88,11 +89,17 @@ if { [string compare [priority_type] multifactor] } {
...
@@ -88,11 +89,17 @@ if { [string compare [priority_type] multifactor] } {
exit $exit_code
exit $exit_code
}
}
# Determine what the selecttype param is
# Determine what the selecttype param is
if {[test_select_type_params "CR_CORE"]} {
if {[test_select_type_params "CR_CORE"]} {
set selectparam 1
set selectparam 1
}
}
# Determine what the selecttype param is
if {[test_select_type_params "CR_ONE_TASK_PER_CORE"]} {
set one_task_pc 1
}
set got_node 0
set got_node 0
spawn $srun -N1 printenv SLURM_NODELIST
spawn $srun -N1 printenv SLURM_NODELIST
expect {
expect {
...
@@ -167,7 +174,7 @@ proc assoc_setup { limit_type limit_val } {
...
@@ -167,7 +174,7 @@ proc assoc_setup { limit_type limit_val } {
proc _test_limits { } {
proc _test_limits { } {
global file_in srun sbatch squeue scancel bin_id number bin_sleep bin_rm ta maxjob_lim maxsub_lim
global file_in srun sbatch squeue scancel bin_id number bin_sleep bin_rm ta maxjob_lim maxsub_lim
global acct_mod_desc acct_mod_acct_vals acct_mod_assoc_vals acct_mod_assoc_test_vals
global acct_mod_desc acct_mod_acct_vals acct_mod_assoc_vals acct_mod_assoc_test_vals
one_task_pc nthreads
set exit_code 0
set exit_code 0
...
@@ -178,6 +185,10 @@ proc _test_limits { } {
...
@@ -178,6 +185,10 @@ proc _test_limits { } {
[string compare $option "grpjobsub"] } {
[string compare $option "grpjobsub"] } {
assoc_setup $option $acct_mod_assoc_vals($option)
assoc_setup $option $acct_mod_assoc_vals($option)
if { ![string compare $option "maxcpumins"] && $one_task_pc } {
set acct_mod_assoc_vals(maxcpumins) "-n [expr [lindex $acct_mod_assoc_vals(maxcpumins) 1] / $nthreads]"
}
if { ![string compare $option "grpwall"] } {
if { ![string compare $option "grpwall"] } {
if { [inc21_21_grpwall $option \
if { [inc21_21_grpwall $option \
$acct_mod_assoc_vals($option)] } {
$acct_mod_assoc_vals($option)] } {
...
...
This diff is collapsed.
Click to expand it.
testsuite/expect/test21.30
+
31
−
0
View file @
bb12c25b
...
@@ -97,6 +97,7 @@ set time_spacing 1
...
@@ -97,6 +97,7 @@ set time_spacing 1
# cr_core = 1 / cr_cpu = 0
# cr_core = 1 / cr_cpu = 0
set selectparam 0
set selectparam 0
set one_task_pc 0
# mod qos
# mod qos
array set mod_qos_vals {
array set mod_qos_vals {
...
@@ -184,6 +185,11 @@ if {[test_select_type_params "CR_CORE"]} {
...
@@ -184,6 +185,11 @@ if {[test_select_type_params "CR_CORE"]} {
set selectparam 1
set selectparam 1
}
}
# Determine what the selecttype param is
if {[test_select_type_params "CR_ONE_TASK_PER_CORE"]} {
set one_task_pc 1
}
set got_node 0
set got_node 0
spawn $srun -N1 printenv SLURM_NODELIST
spawn $srun -N1 printenv SLURM_NODELIST
expect {
expect {
...
@@ -238,6 +244,8 @@ if {$totcpus == 0} {
...
@@ -238,6 +244,8 @@ if {$totcpus == 0} {
set maxcpumin_num $totcpus
set maxcpumin_num $totcpus
}
}
# Get the number of nodes in the default partition
# Get the number of nodes in the default partition
set num_nodes 0
set num_nodes 0
spawn $scontrol show partition [default_partition]
spawn $scontrol show partition [default_partition]
...
@@ -454,6 +462,11 @@ set mod_qos_vals(GrpNodes) "-1"
...
@@ -454,6 +462,11 @@ set mod_qos_vals(GrpNodes) "-1"
set mod_qos_vals(GrpCpus) $grcpu_num
set mod_qos_vals(GrpCpus) $grcpu_num
mod_qos $qostest [array get mod_qos_vals]
mod_qos $qostest [array get mod_qos_vals]
sleep $time_spacing
sleep $time_spacing
if { $one_task_pc } {
set grcpu_num [expr $grcpu_num / $nthreads]
}
inc21_30_2
inc21_30_2
if {$exit_code != 0} {
if {$exit_code != 0} {
endit
endit
...
@@ -490,6 +503,12 @@ set mod_qos_vals(GrpSubmit) "-1"
...
@@ -490,6 +503,12 @@ set mod_qos_vals(GrpSubmit) "-1"
set mod_qos_vals(MaxCpus) $maxcpu_num
set mod_qos_vals(MaxCpus) $maxcpu_num
mod_qos $qostest [array get mod_qos_vals]
mod_qos $qostest [array get mod_qos_vals]
sleep $time_spacing
sleep $time_spacing
if { $one_task_pc } {
set maxcpu_num [expr $maxcpu_num / $nthreads]
}
inc21_30_5
inc21_30_5
if {$exit_code != 0} {
if {$exit_code != 0} {
endit
endit
...
@@ -538,6 +557,9 @@ set mod_qos_vals(MaxSubmitJobs) "-1"
...
@@ -538,6 +557,9 @@ set mod_qos_vals(MaxSubmitJobs) "-1"
set mod_qos_vals(GrpCpuMin) $grpcpumin_num
set mod_qos_vals(GrpCpuMin) $grpcpumin_num
mod_qos $qostest [array get mod_qos_vals]
mod_qos $qostest [array get mod_qos_vals]
sleep $time_spacing
sleep $time_spacing
if { $one_task_pc } {
set grpcpumin_num [expr $grpcpumin_num / $nthreads]
}
inc21_30_9
inc21_30_9
if {$exit_code != 0 } {
if {$exit_code != 0 } {
endit
endit
...
@@ -552,6 +574,9 @@ if { $prio_multifactor != 0 } {
...
@@ -552,6 +574,9 @@ if { $prio_multifactor != 0 } {
set mod_qos_vals(GrpCpuRunMin) $grpcpurunmin_num
set mod_qos_vals(GrpCpuRunMin) $grpcpurunmin_num
mod_qos $qostest [array get mod_qos_vals]
mod_qos $qostest [array get mod_qos_vals]
sleep $time_spacing
sleep $time_spacing
if { $one_task_pc } {
set grpcpurunmin_num [expr $grpcpurunmin_num / $nthreads]
}
inc21_30_10
inc21_30_10
if {$exit_code != 0 } {
if {$exit_code != 0 } {
endit
endit
...
@@ -592,6 +617,9 @@ if { $prio_multifactor != 0 } {
...
@@ -592,6 +617,9 @@ if { $prio_multifactor != 0 } {
set mod_qos_vals(MaxCpuMin) $maxcpumin_num
set mod_qos_vals(MaxCpuMin) $maxcpumin_num
mod_qos $qostest [array get mod_qos_vals]
mod_qos $qostest [array get mod_qos_vals]
sleep $time_spacing
sleep $time_spacing
if { $one_task_pc } {
set maxcpumin_num [expr $maxcpumin_num / $nthreads]
}
inc21_30_13
inc21_30_13
if {$exit_code != 0 } {
if {$exit_code != 0 } {
endit
endit
...
@@ -622,6 +650,9 @@ if {$selectparam} {
...
@@ -622,6 +650,9 @@ if {$selectparam} {
set mod_qos_vals(MaxCpusPerUser) $maxcpuspu_num
set mod_qos_vals(MaxCpusPerUser) $maxcpuspu_num
mod_qos $qostest [array get mod_qos_vals]
mod_qos $qostest [array get mod_qos_vals]
sleep $time_spacing
sleep $time_spacing
if { $one_task_pc } {
set maxcpuspu_num [expr $maxcpuspu_num / $nthreads]
}
inc21_30_15
inc21_30_15
if {$exit_code != 0 } {
if {$exit_code != 0 } {
endit
endit
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment