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
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
felixkhals
SWP-CM22-Planbased OMPI
Compare revisions
bugfix/rank_setting to master
Compare revisions
Changes are shown as if the
source
revision was being merged into the
target
revision.
Learn more about comparing revisions.
Source
felixkhals/swp-cm22-planbased-mpi
Select target project
No results found
master
Select Git revision
Branches
bugfix/debug_print
bugfix/rank_setting
master
3 results
Swap
Target
becker29/master-thesis-custom-ompi
Select target project
becker29/master-thesis-custom-ompi
felixkhals/swp-cm22-planbased-mpi
2 results
bugfix/rank_setting
Select Git revision
Branches
bugfix/debug_print
bugfix/rank_setting
master
3 results
Show changes
Only incoming changes from source
Include changes to target since source was created
Compare
Commits on Source (1)
Fix rank modification
· 081262b0
FKHals
authored
2 years ago
081262b0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
ompi/communicator/comm_init.c
+6
-13
6 additions, 13 deletions
ompi/communicator/comm_init.c
with
6 additions
and
13 deletions
ompi/communicator/comm_init.c
View file @
081262b0
...
...
@@ -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
]);
}
}
...
...
This diff is collapsed.
Click to expand it.