Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Revert "Silly workaround for coverage build with gcc-10."
[simgrid.git] / teshsuite / smpi / mpich3-test / f90 / coll / uallreducef90.f90
index cd0ae1e..574d649 100644 (file)
@@ -7,6 +7,22 @@
 !
 ! Test user-defined operations.  This tests a simple commutative operation
 !
+      subroutine uop( cin, cout, count, datatype )
+      use mpi
+      integer cin(*), cout(*)
+      integer count, datatype
+      integer i
+      
+      if (datatype .ne. MPI_INTEGER) then
+         print *, 'Invalid datatype (',datatype,') passed to user_op()'
+         return
+      endif
+
+      do i=1, count
+         cout(i) = cin(i) + cout(i)
+      enddo
+      end
+
       program main
       use mpi
       external uop
       call mtest_finalize(errs)
       call mpi_finalize(ierr)
       end
-
-      subroutine uop( cin, cout, count, datatype )
-      use mpi
-      integer cin(*), cout(*)
-      integer count, datatype
-      integer i
-      
-      if (datatype .ne. MPI_INTEGER) then
-         print *, 'Invalid datatype (',datatype,') passed to user_op()'
-         return
-      endif
-
-      do i=1, count
-         cout(i) = cin(i) + cout(i)
-      enddo
-      end