From 2e4e4718c385d365320dfc5bca156386255b13a4 Mon Sep 17 00:00:00 2001 From: Sergey Lebedev Date: Tue, 10 Oct 2023 09:14:13 +0000 Subject: [PATCH] REVIEW: fix review comments --- test/mpi/test_allgather.cc | 4 ++-- test/mpi/test_alltoall.cc | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/test/mpi/test_allgather.cc b/test/mpi/test_allgather.cc index e0006f08f1..9690976874 100644 --- a/test/mpi/test_allgather.cc +++ b/test/mpi/test_allgather.cc @@ -72,12 +72,12 @@ ucc_status_t TestAllgather::set_input(int iter_persistent) ucc_status_t TestAllgather::check() { size_t dt_size, single_rank_count; - int size; + int size, i; MPI_Comm_size(team.comm, &size); single_rank_count = args.dst.info.count / size; dt_size = ucc_dt_size(dt); - for (int i = 0; i < size; i++) { + for (i = 0; i < size; i++) { init_buffer(PTR_OFFSET(check_buf, i * single_rank_count * dt_size), single_rank_count, dt, mem_type, i * (iter_persistent + 1)); } diff --git a/test/mpi/test_alltoall.cc b/test/mpi/test_alltoall.cc index a171654a2d..c66a5099fa 100644 --- a/test/mpi/test_alltoall.cc +++ b/test/mpi/test_alltoall.cc @@ -100,14 +100,14 @@ ucc_status_t TestAlltoall::set_input(int iter_persistent) ucc_status_t TestAlltoall::check() { - int size, rank; - size_t single_rank_count; + int size, rank, i; + size_t single_rank_count; MPI_Comm_rank(team.comm, &rank); MPI_Comm_size(team.comm, &size); single_rank_count = args.src.info.count / size; - for (int i = 0; i < size; i++) { + for ( i = 0; i < size; i++) { init_buffer(PTR_OFFSET(check_buf, i * single_rank_count * ucc_dt_size(dt)), single_rank_count, dt, mem_type, i * (iter_persistent + 1), single_rank_count * rank);