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
4d4c8c17
Commit
4d4c8c17
authored
9 years ago
by
Artem Polyakov
Committed by
David Bigagli
9 years ago
Browse files
Options
Downloads
Patches
Plain Diff
1. Prepare to the new state machine 2. Fail with SIGKILL if state machine misbehaves.
parent
195ae448
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/plugins/mpi/pmix/pmixp_coll.c
+22
-3
22 additions, 3 deletions
src/plugins/mpi/pmix/pmixp_coll.c
src/plugins/mpi/pmix/pmixp_coll.h
+0
-2
0 additions, 2 deletions
src/plugins/mpi/pmix/pmixp_coll.h
src/plugins/mpi/pmix/pmixp_server.c
+15
-9
15 additions, 9 deletions
src/plugins/mpi/pmix/pmixp_server.c
with
37 additions
and
14 deletions
src/plugins/mpi/pmix/pmixp_coll.c
+
22
−
3
View file @
4d4c8c17
...
...
@@ -99,6 +99,26 @@ static int _pack_ranges(pmixp_coll_t *coll)
return
SLURM_SUCCESS
;
}
static
void
_fan_in_finished
(
pmixp_coll_t
*
coll
)
{
xassert
(
PMIXP_COLL_FAN_IN
==
coll
->
state
);
coll
->
state
=
PMIXP_COLL_FAN_OUT
;
memset
(
coll
->
ch_contribs
,
0
,
sizeof
(
int
)
*
coll
->
children_cnt
);
coll
->
contrib_cntr
=
0
;
coll
->
contrib_local
=
0
;
set_buf_offset
(
coll
->
buf
,
coll
->
serv_offs
);
if
(
SLURM_SUCCESS
!=
_pack_ranges
(
coll
))
{
PMIXP_ERROR
(
"Cannot pack ranges to coll message header!"
);
}
}
static
void
_fan_out_finished
(
pmixp_coll_t
*
coll
)
{
xassert
(
PMIXP_COLL_FAN_OUT
==
coll
->
state
/* || fan_out_in */
);
coll
->
state
=
PMIXP_COLL_SYNC
;
coll
->
seq
++
;
/* move to the next collective */
}
static
void
_reset_coll
(
pmixp_coll_t
*
coll
)
{
switch
(
coll
->
state
)
{
...
...
@@ -535,8 +555,7 @@ static void _progress_fan_in(pmixp_coll_t *coll)
}
/* transit to the next state */
coll
->
state
=
PMIXP_COLL_FAN_OUT
;
set_buf_offset
(
coll
->
buf
,
0
);
_fan_in_finished
(
coll
);
/* if we are root - push data to PMIx here.
* Originally there was a homogenuous solution: root nodename was in the hostlist.
...
...
@@ -577,7 +596,7 @@ void _progres_fan_out(pmixp_coll_t *coll, Buf buf)
pmixp_free_Buf
,
(
void
*
)
buf
);
}
/* Prepare for the next collective operation */
_
reset_coll
(
coll
);
_
fan_out_finished
(
coll
);
PMIXP_DEBUG
(
"%s:%d: collective is prepared for the next use"
,
pmixp_info_namespace
(),
pmixp_info_nodeid
());
...
...
This diff is collapsed.
Click to expand it.
src/plugins/mpi/pmix/pmixp_coll.h
+
0
−
2
View file @
4d4c8c17
...
...
@@ -170,8 +170,6 @@ static inline int pmixp_coll_check_seq(pmixp_coll_t *coll, uint32_t seq,
* want to discard this message */
return
SLURM_ERROR
;
}
PMIXP_ERROR
(
"Bad collective seq. #%d from %s, current is %d"
,
seq
,
nodename
,
coll
->
seq
);
/* maybe need more sophisticated handling in presence of
* several steps. However maybe it's enough to just ignore */
/* slurm_kill_job_step(pmixp_info_jobid(), pmixp_info_stepid(), SIGKILL); */
...
...
This diff is collapsed.
Click to expand it.
src/plugins/mpi/pmix/pmixp_server.c
+
15
−
9
View file @
4d4c8c17
...
...
@@ -411,16 +411,22 @@ static void _process_server_request(recv_header_t *_hdr, void *payload)
coll
=
pmixp_state_coll_get
(
type
,
procs
,
nprocs
);
xfree
(
procs
);
PMIXP_DEBUG
(
"FENCE collective message from node
\"
%s
\"
, type = %s"
,
nodename
,
(
PMIXP_MSG_FAN_IN
==
hdr
->
type
)
?
"fan-in"
:
"fan-out"
);
if
(
SLURM_SUCCESS
!=
pmixp_coll_check_seq
(
coll
,
hdr
->
seq
,
PMIXP_DEBUG
(
"FENCE collective message from node
\"
%s
\"
, type = %s"
,
nodename
,
(
PMIXP_MSG_FAN_IN
==
hdr
->
type
)
?
"fan-in"
:
"fan-out"
);
if
(
SLURM_SUCCESS
!=
pmixp_coll_check_seq
(
coll
,
hdr
->
seq
,
nodename
))
{
/* stop processing discardig this message */
/* this is unexepable event: either something went
* really wrong or the state machine is incorrect.
* This will 100% lead to application hang.
*/
PMIXP_ERROR
(
"Bad collective seq. #%d from %s, current is %d"
,
hdr
->
seq
,
nodename
,
coll
->
seq
);
pmixp_debug_hang
(
0
);
/* enable hang to debug this! */
slurm_kill_job_step
(
pmixp_info_jobid
(),
pmixp_info_stepid
(),
SIGKILL
);
break
;
}
...
...
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