From: Augustin Degomme Date: Mon, 7 Jun 2021 14:32:21 +0000 (+0200) Subject: get_accumulate: if MPI_NO_OP is specified, origin* inputs are irrelevant X-Git-Tag: v3.28~133 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/5eca5225831a402a9033e46f8f625bcd46f83f80 get_accumulate: if MPI_NO_OP is specified, origin* inputs are irrelevant + activate test. --- diff --git a/src/smpi/bindings/smpi_pmpi_win.cpp b/src/smpi/bindings/smpi_pmpi_win.cpp index c56066646f..15e008f309 100644 --- a/src/smpi/bindings/smpi_pmpi_win.cpp +++ b/src/smpi/bindings/smpi_pmpi_win.cpp @@ -324,11 +324,13 @@ int PMPI_Raccumulate(const void *origin_addr, int origin_count, MPI_Datatype ori int PMPI_Get_accumulate(const void *origin_addr, int origin_count, MPI_Datatype origin_datatype, void *result_addr, int result_count, MPI_Datatype result_datatype, int target_rank, MPI_Aint target_disp, int target_count, MPI_Datatype target_datatype, MPI_Op op, MPI_Win win){ - CHECK_COUNT(2, origin_count) - if(origin_count>0) - CHECK_TYPE(3, origin_datatype) - if (op != MPI_NO_OP) + + if (op != MPI_NO_OP){ CHECK_BUFFER(1, origin_addr, origin_count, origin_datatype) + CHECK_COUNT(2, origin_count) + if(origin_count>0) + CHECK_TYPE(3, origin_datatype) + } CHECK_COUNT(5, result_count) CHECK_TYPE(6, result_datatype) CHECK_BUFFER(4, result_addr, result_count, result_datatype) @@ -366,9 +368,12 @@ int result_count, MPI_Datatype result_datatype, int target_rank, MPI_Aint target MPI_Datatype target_datatype, MPI_Op op, MPI_Win win, MPI_Request* request){ if(target_rank==MPI_PROC_NULL) *request = MPI_REQUEST_NULL; - CHECK_COUNT(2, origin_count) - CHECK_TYPE(3, origin_datatype) - CHECK_BUFFER(1, origin_addr, origin_count, origin_datatype) + if (op != MPI_NO_OP){ + CHECK_BUFFER(1, origin_addr, origin_count, origin_datatype) + CHECK_COUNT(2, origin_count) + if(origin_count>0) + CHECK_TYPE(3, origin_datatype) + } CHECK_COUNT(5, result_count) CHECK_TYPE(6, result_datatype) CHECK_BUFFER(4, result_addr, result_count, result_datatype) diff --git a/teshsuite/smpi/mpich3-test/rma/CMakeLists.txt b/teshsuite/smpi/mpich3-test/rma/CMakeLists.txt index d4b2710373..908dcdda06 100644 --- a/teshsuite/smpi/mpich3-test/rma/CMakeLists.txt +++ b/teshsuite/smpi/mpich3-test/rma/CMakeLists.txt @@ -19,13 +19,13 @@ if(enable_smpi AND enable_smpi_MPICH3_testsuite) strided_acc_onelock strided_get_indexed strided_putget_indexed contention_put contention_putget lockcontention3 adlb_mimic1 lock_contention_dt acc-loc get_acc_local get_accumulate put_base put_bottom linked_list_bench_lock_all linked_list_bench_lock_excl manyrma2 pscw_ordering rma-contig get-struct - rput_local_comp racc_local_comp rget-testall win_shared win_shared_put_flush_get) + rput_local_comp racc_local_comp rget-testall win_shared win_shared_put_flush_get atomic_get) # fence_shm fetchandadd_am fetchandadd fetchandadd_tree_am fetchandadd_tree # linked_list_bench_lock_shr linked_list linked_list_fop linked_list_lockall # mcs-mutex mixedsync mutex_bench reqops # strided_getacc_indexed_shared rget-unlock # win_flavors win_shared_zerobyte win_shared_noncontig win_shared_noncontig_put - # win_large_shm win_zero wintest atomic_rmw_fop atomic_rmw_gacc atomic_get atomic_rmw_cas + # win_large_shm win_zero wintest atomic_rmw_fop atomic_rmw_gacc atomic_rmw_cas # aint derived-acc-flush_local large-acc-flush_local # win_shared_create win_shared_put_flush_get win_shared_rma_flush_load # wrma_flush_get diff --git a/teshsuite/smpi/mpich3-test/rma/testlist b/teshsuite/smpi/mpich3-test/rma/testlist index 6f920efdbf..c49b81f06c 100644 --- a/teshsuite/smpi/mpich3-test/rma/testlist +++ b/teshsuite/smpi/mpich3-test/rma/testlist @@ -137,7 +137,7 @@ at_complete 2 #atomic_rmw_fop 3 #atomic_rmw_cas 3 #atomic_rmw_gacc 3 -#atomic_get 3 mpiversion=3.0 timeLimit=300 +atomic_get 3 mpiversion=3.0 timeLimit=300 #aint 2 mpiversion=3.1 #acc-pairtype 2 manyget 2