Skip to content

Commit a2868ac

Browse files
coll/ucc: fix int overflow in coll init
Signed-off-by: Sergey Lebedev <[email protected]> bot:notacherrypick
1 parent 6f08eaf commit a2868ac

11 files changed

+15
-15
lines changed

ompi/mca/coll/ucc/coll_ucc_allgather.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99

1010
#include "coll_ucc_common.h"
1111

12-
static inline ucc_status_t mca_coll_ucc_allgather_init(const void *sbuf, int scount, struct ompi_datatype_t *sdtype,
13-
void* rbuf, int rcount, struct ompi_datatype_t *rdtype,
12+
static inline ucc_status_t mca_coll_ucc_allgather_init(const void *sbuf, size_t scount, struct ompi_datatype_t *sdtype,
13+
void* rbuf, size_t rcount, struct ompi_datatype_t *rdtype,
1414
mca_coll_ucc_module_t *ucc_module,
1515
ucc_coll_req_h *req,
1616
mca_coll_ucc_req_t *coll_req)

ompi/mca/coll/ucc/coll_ucc_allgatherv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
#include "coll_ucc_common.h"
1111

12-
static inline ucc_status_t mca_coll_ucc_allgatherv_init(const void *sbuf, int scount,
12+
static inline ucc_status_t mca_coll_ucc_allgatherv_init(const void *sbuf, size_t scount,
1313
struct ompi_datatype_t *sdtype,
1414
void* rbuf, const int *rcounts, const int *rdisps,
1515
struct ompi_datatype_t *rdtype,

ompi/mca/coll/ucc/coll_ucc_allreduce.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
#include "coll_ucc_common.h"
1111

12-
static inline ucc_status_t mca_coll_ucc_allreduce_init(const void *sbuf, void *rbuf, int count,
12+
static inline ucc_status_t mca_coll_ucc_allreduce_init(const void *sbuf, void *rbuf, size_t count,
1313
struct ompi_datatype_t *dtype,
1414
struct ompi_op_t *op, mca_coll_ucc_module_t *ucc_module,
1515
ucc_coll_req_h *req,

ompi/mca/coll/ucc/coll_ucc_alltoall.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99

1010
#include "coll_ucc_common.h"
1111

12-
static inline ucc_status_t mca_coll_ucc_alltoall_init(const void *sbuf, int scount, struct ompi_datatype_t *sdtype,
13-
void* rbuf, int rcount, struct ompi_datatype_t *rdtype,
12+
static inline ucc_status_t mca_coll_ucc_alltoall_init(const void *sbuf, size_t scount, struct ompi_datatype_t *sdtype,
13+
void* rbuf, size_t rcount, struct ompi_datatype_t *rdtype,
1414
mca_coll_ucc_module_t *ucc_module,
1515
ucc_coll_req_h *req,
1616
mca_coll_ucc_req_t *coll_req)

ompi/mca/coll/ucc/coll_ucc_bcast.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
#include "coll_ucc_common.h"
1010

11-
static inline ucc_status_t mca_coll_ucc_bcast_init(void *buf, int count, struct ompi_datatype_t *dtype,
11+
static inline ucc_status_t mca_coll_ucc_bcast_init(void *buf, size_t count, struct ompi_datatype_t *dtype,
1212
int root, mca_coll_ucc_module_t *ucc_module,
1313
ucc_coll_req_h *req,
1414
mca_coll_ucc_req_t *coll_req)

ompi/mca/coll/ucc/coll_ucc_gather.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
#include "coll_ucc_common.h"
1212

1313
static inline
14-
ucc_status_t mca_coll_ucc_gather_init(const void *sbuf, int scount, struct ompi_datatype_t *sdtype,
15-
void *rbuf, int rcount, struct ompi_datatype_t *rdtype,
14+
ucc_status_t mca_coll_ucc_gather_init(const void *sbuf, size_t scount, struct ompi_datatype_t *sdtype,
15+
void *rbuf, size_t rcount, struct ompi_datatype_t *rdtype,
1616
int root, mca_coll_ucc_module_t *ucc_module,
1717
ucc_coll_req_h *req,
1818
mca_coll_ucc_req_t *coll_req)

ompi/mca/coll/ucc/coll_ucc_gatherv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
#include "coll_ucc_common.h"
1212

13-
static inline ucc_status_t mca_coll_ucc_gatherv_init(const void *sbuf, int scount, struct ompi_datatype_t *sdtype,
13+
static inline ucc_status_t mca_coll_ucc_gatherv_init(const void *sbuf, size_t scount, struct ompi_datatype_t *sdtype,
1414
void *rbuf, const int *rcounts, const int *disps,
1515
struct ompi_datatype_t *rdtype, int root,
1616
mca_coll_ucc_module_t *ucc_module,

ompi/mca/coll/ucc/coll_ucc_reduce.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
#include "coll_ucc_common.h"
1010

11-
static inline ucc_status_t mca_coll_ucc_reduce_init(const void *sbuf, void *rbuf, int count,
11+
static inline ucc_status_t mca_coll_ucc_reduce_init(const void *sbuf, void *rbuf, size_t count,
1212
struct ompi_datatype_t *dtype,
1313
struct ompi_op_t *op, int root,
1414
mca_coll_ucc_module_t *ucc_module,

ompi/mca/coll/ucc/coll_ucc_reduce_scatter_block.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
static inline
1313
ucc_status_t mca_coll_ucc_reduce_scatter_block_init(const void *sbuf, void *rbuf,
14-
int rcount,
14+
size_t rcount,
1515
struct ompi_datatype_t *dtype,
1616
struct ompi_op_t *op,
1717
mca_coll_ucc_module_t *ucc_module,

ompi/mca/coll/ucc/coll_ucc_scatter.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
#include "coll_ucc_common.h"
1111

1212
static inline
13-
ucc_status_t mca_coll_ucc_scatter_init(const void *sbuf, int scount,
13+
ucc_status_t mca_coll_ucc_scatter_init(const void *sbuf, size_t scount,
1414
struct ompi_datatype_t *sdtype,
15-
void *rbuf, int rcount,
15+
void *rbuf, size_t rcount,
1616
struct ompi_datatype_t *rdtype, int root,
1717
mca_coll_ucc_module_t *ucc_module,
1818
ucc_coll_req_h *req,

0 commit comments

Comments
 (0)