Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
SWP-CM22-Planbased OMPI
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
felixkhals
SWP-CM22-Planbased OMPI
Merge requests
!7
Fix rank modification
Code
Review changes
Check out branch
Open in Workspace
Download
Patches
Plain diff
Expand sidebar
Merged
Fix rank modification
bugfix/rank_manipulation
into
master
Overview
0
Commits
1
Pipelines
0
Changes
1
Merged
Fix rank modification
felixkhals
requested to merge
bugfix/rank_manipulation
into
master
Sep 30, 2022
Overview
0
Commits
1
Pipelines
0
Changes
1
0
0
Merge request reports
Compare
master
master (base)
and
latest version
latest version
081262b0
1 commit,
Sep 30, 2022
1 file
+
6
−
13
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
ompi/communicator/comm_init.c
+
6
−
13
View file @ 081262b0
Edit in single-file editor
Open in Web IDE
Show full file
@@ -197,14 +197,6 @@ static int get_modified_ranks(uint32_t jobid, uint32_t vpid, size_t size, opal_v
free
(
rank_to_recv
);
// // Print modified_ranks array for debugging purposes
// printf("modified_ranks: [");
// for (size_t i = 0; i < size; i++) {
// printf("%u", modified_ranks[i]);
// if (i+1 < size) printf(", ");
// }
// printf("]\n");
close
(
socket_fd
);
return
0
;
@@ -246,14 +238,15 @@ int ompi_comm_init(void)
get_modified_ranks
(
OMPI_PROC_MY_NAME
->
jobid
,
OMPI_PROC_MY_NAME
->
vpid
,
size
,
modified_ranks
);
for
(
size_t
i
=
0
;
i
<
size
;
++
i
)
{
opal_process_name_t
name
=
{.
vpid
=
modified_ranks
[
i
],
.
jobid
=
OMPI_PROC_MY_NAME
->
jobid
};
opal_vpid_t
modified_rank
=
modified_ranks
[
i
];
opal_process_name_t
name
=
{.
vpid
=
i
,
.
jobid
=
OMPI_PROC_MY_NAME
->
jobid
};
/* look for existing ompi_proc_t that matches this name */
group
->
grp_proc_pointers
[
i
]
=
(
ompi_proc_t
*
)
ompi_proc_lookup
(
name
);
if
(
NULL
==
group
->
grp_proc_pointers
[
i
])
{
group
->
grp_proc_pointers
[
modified_rank
]
=
(
ompi_proc_t
*
)
ompi_proc_lookup
(
name
);
if
(
NULL
==
group
->
grp_proc_pointers
[
modified_rank
])
{
/* set sentinel value */
group
->
grp_proc_pointers
[
i
]
=
(
ompi_proc_t
*
)
ompi_proc_name_to_sentinel
(
name
);
group
->
grp_proc_pointers
[
modified_rank
]
=
(
ompi_proc_t
*
)
ompi_proc_name_to_sentinel
(
name
);
}
else
{
OBJ_RETAIN
(
group
->
grp_proc_pointers
[
i
]);
OBJ_RETAIN
(
group
->
grp_proc_pointers
[
modified_rank
]);
}
}
Loading