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
264b950d
Commit
264b950d
authored
9 years ago
by
Danny Auble
Browse files
Options
Downloads
Patches
Plain Diff
Continuation to commit
701917cc
to make sure we are running
gang scheduling before doing code for gang scheduling.
parent
54f314e7
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/slurmctld/gang.c
+18
-0
18 additions, 0 deletions
src/slurmctld/gang.c
with
18 additions
and
0 deletions
src/slurmctld/gang.c
+
18
−
0
View file @
264b950d
...
@@ -1178,6 +1178,9 @@ static void _spawn_timeslicer_thread(void)
...
@@ -1178,6 +1178,9 @@ static void _spawn_timeslicer_thread(void)
/* Initialize data structures and start the gang scheduling thread */
/* Initialize data structures and start the gang scheduling thread */
extern
int
gs_init
(
void
)
extern
int
gs_init
(
void
)
{
{
if
(
!
(
slurmctld_conf
.
preempt_mode
&
PREEMPT_MODE_GANG
))
return
SLURM_SUCCESS
;
if
(
timeslicer_thread_id
)
if
(
timeslicer_thread_id
)
return
SLURM_SUCCESS
;
return
SLURM_SUCCESS
;
...
@@ -1244,6 +1247,9 @@ extern int gs_job_start(struct job_record *job_ptr)
...
@@ -1244,6 +1247,9 @@ extern int gs_job_start(struct job_record *job_ptr)
uint16_t
job_sig_state
;
uint16_t
job_sig_state
;
char
*
part_name
;
char
*
part_name
;
if
(
!
(
slurmctld_conf
.
preempt_mode
&
PREEMPT_MODE_GANG
))
return
SLURM_SUCCESS
;
if
(
slurmctld_conf
.
debug_flags
&
DEBUG_FLAG_GANG
)
if
(
slurmctld_conf
.
debug_flags
&
DEBUG_FLAG_GANG
)
info
(
"gang: entering gs_job_start for job %u"
,
job_ptr
->
job_id
);
info
(
"gang: entering gs_job_start for job %u"
,
job_ptr
->
job_id
);
/* add job to partition */
/* add job to partition */
...
@@ -1280,6 +1286,9 @@ extern int gs_job_start(struct job_record *job_ptr)
...
@@ -1280,6 +1286,9 @@ extern int gs_job_start(struct job_record *job_ptr)
* to remove */
* to remove */
extern
int
gs_job_scan
(
void
)
extern
int
gs_job_scan
(
void
)
{
{
if
(
!
(
slurmctld_conf
.
preempt_mode
&
PREEMPT_MODE_GANG
))
return
SLURM_SUCCESS
;
if
(
slurmctld_conf
.
debug_flags
&
DEBUG_FLAG_GANG
)
if
(
slurmctld_conf
.
debug_flags
&
DEBUG_FLAG_GANG
)
info
(
"gang: entering gs_job_scan"
);
info
(
"gang: entering gs_job_scan"
);
pthread_mutex_lock
(
&
data_mutex
);
pthread_mutex_lock
(
&
data_mutex
);
...
@@ -1300,6 +1309,9 @@ extern void gs_wake_jobs(void)
...
@@ -1300,6 +1309,9 @@ extern void gs_wake_jobs(void)
struct
job_record
*
job_ptr
;
struct
job_record
*
job_ptr
;
ListIterator
job_iterator
;
ListIterator
job_iterator
;
if
(
!
(
slurmctld_conf
.
preempt_mode
&
PREEMPT_MODE_GANG
))
return
;
if
(
!
job_list
)
/* no jobs */
if
(
!
job_list
)
/* no jobs */
return
;
return
;
...
@@ -1320,6 +1332,9 @@ extern int gs_job_fini(struct job_record *job_ptr)
...
@@ -1320,6 +1332,9 @@ extern int gs_job_fini(struct job_record *job_ptr)
struct
gs_part
*
p_ptr
;
struct
gs_part
*
p_ptr
;
char
*
part_name
;
char
*
part_name
;
if
(
!
(
slurmctld_conf
.
preempt_mode
&
PREEMPT_MODE_GANG
))
return
SLURM_SUCCESS
;
if
(
slurmctld_conf
.
debug_flags
&
DEBUG_FLAG_GANG
)
if
(
slurmctld_conf
.
debug_flags
&
DEBUG_FLAG_GANG
)
info
(
"gang: entering gs_job_fini for job %u"
,
job_ptr
->
job_id
);
info
(
"gang: entering gs_job_fini for job %u"
,
job_ptr
->
job_id
);
if
(
job_ptr
->
part_ptr
&&
job_ptr
->
part_ptr
->
name
)
if
(
job_ptr
->
part_ptr
&&
job_ptr
->
part_ptr
->
name
)
...
@@ -1377,6 +1392,9 @@ extern int gs_reconfig(void)
...
@@ -1377,6 +1392,9 @@ extern int gs_reconfig(void)
struct
job_record
*
job_ptr
;
struct
job_record
*
job_ptr
;
struct
gs_job
*
j_ptr
;
struct
gs_job
*
j_ptr
;
if
(
!
(
slurmctld_conf
.
preempt_mode
&
PREEMPT_MODE_GANG
))
return
SLURM_SUCCESS
;
if
(
!
timeslicer_thread_id
)
{
if
(
!
timeslicer_thread_id
)
{
/* gs_init() will be called later from read_slurm_conf()
/* gs_init() will be called later from read_slurm_conf()
* if we are enabling gang scheduling via reconfiguration */
* if we are enabling gang scheduling via reconfiguration */
...
...
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