summaryrefslogtreecommitdiffstats
path: root/fortran/testpar/ptest.F90
diff options
context:
space:
mode:
Diffstat (limited to 'fortran/testpar/ptest.F90')
-rw-r--r--fortran/testpar/ptest.F904
1 files changed, 3 insertions, 1 deletions
diff --git a/fortran/testpar/ptest.F90 b/fortran/testpar/ptest.F90
index 30abb88..0883ac2 100644
--- a/fortran/testpar/ptest.F90
+++ b/fortran/testpar/ptest.F90
@@ -29,7 +29,7 @@ PROGRAM parallel_test
INTEGER :: mpi_size ! number of processes in the group of communicator
INTEGER :: mpi_rank ! rank of the calling process in the communicator
INTEGER :: length = 12000 ! length of array
- INTEGER :: i,j
+ INTEGER :: i,j, sum
! use collective MPI I/O
LOGICAL, DIMENSION(1:2) :: do_collective = (/.FALSE.,.TRUE./)
CHARACTER(LEN=11), DIMENSION(1:2) :: chr_collective =(/"independent", "collective "/)
@@ -82,6 +82,8 @@ PROGRAM parallel_test
!
CALL h5close_f(hdferror)
+ CALL MPI_ALLREDUCE(total_error, sum, 1, MPI_INTEGER, MPI_SUM, MPI_COMM_WORLD, mpierror)
+
!
! close MPI
!