Skip to content

Commit 74f9e24

Browse files
authored
Merge pull request #10544 from gkatev/main2
coll/UCC: Fix uninitialized saved-coll-module-pointer use scenario
2 parents b5bec96 + af4dd97 commit 74f9e24

File tree

1 file changed

+33
-17
lines changed

1 file changed

+33
-17
lines changed

ompi/mca/coll/ucc/coll_ucc_module.c

Lines changed: 33 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -29,23 +29,39 @@ int mca_coll_ucc_init_query(bool enable_progress_threads, bool enable_mpi_thread
2929

3030
static void mca_coll_ucc_module_clear(mca_coll_ucc_module_t *ucc_module)
3131
{
32-
ucc_module->ucc_team = NULL;
33-
ucc_module->previous_allreduce = NULL;
34-
ucc_module->previous_iallreduce = NULL;
35-
ucc_module->previous_barrier = NULL;
36-
ucc_module->previous_ibarrier = NULL;
37-
ucc_module->previous_bcast = NULL;
38-
ucc_module->previous_ibcast = NULL;
39-
ucc_module->previous_alltoall = NULL;
40-
ucc_module->previous_ialltoall = NULL;
41-
ucc_module->previous_alltoallv = NULL;
42-
ucc_module->previous_ialltoallv = NULL;
43-
ucc_module->previous_allgather = NULL;
44-
ucc_module->previous_iallgather = NULL;
45-
ucc_module->previous_allgatherv = NULL;
46-
ucc_module->previous_iallgatherv = NULL;
47-
ucc_module->previous_reduce = NULL;
48-
ucc_module->previous_ireduce = NULL;
32+
ucc_module->ucc_team = NULL;
33+
ucc_module->previous_allreduce = NULL;
34+
ucc_module->previous_allreduce_module = NULL;
35+
ucc_module->previous_iallreduce = NULL;
36+
ucc_module->previous_iallreduce_module = NULL;
37+
ucc_module->previous_barrier = NULL;
38+
ucc_module->previous_barrier_module = NULL;
39+
ucc_module->previous_ibarrier = NULL;
40+
ucc_module->previous_ibarrier_module = NULL;
41+
ucc_module->previous_bcast = NULL;
42+
ucc_module->previous_bcast_module = NULL;
43+
ucc_module->previous_ibcast = NULL;
44+
ucc_module->previous_ibcast_module = NULL;
45+
ucc_module->previous_alltoall = NULL;
46+
ucc_module->previous_alltoall_module = NULL;
47+
ucc_module->previous_ialltoall = NULL;
48+
ucc_module->previous_ialltoall_module = NULL;
49+
ucc_module->previous_alltoallv = NULL;
50+
ucc_module->previous_alltoallv_module = NULL;
51+
ucc_module->previous_ialltoallv = NULL;
52+
ucc_module->previous_ialltoallv_module = NULL;
53+
ucc_module->previous_allgather = NULL;
54+
ucc_module->previous_allgather_module = NULL;
55+
ucc_module->previous_iallgather = NULL;
56+
ucc_module->previous_iallgather_module = NULL;
57+
ucc_module->previous_allgatherv = NULL;
58+
ucc_module->previous_allgatherv_module = NULL;
59+
ucc_module->previous_iallgatherv = NULL;
60+
ucc_module->previous_iallgatherv_module = NULL;
61+
ucc_module->previous_reduce = NULL;
62+
ucc_module->previous_reduce_module = NULL;
63+
ucc_module->previous_ireduce = NULL;
64+
ucc_module->previous_ireduce_module = NULL;
4965
}
5066

5167
static void mca_coll_ucc_module_construct(mca_coll_ucc_module_t *ucc_module)

0 commit comments

Comments
 (0)