ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/mdtools/md_code/mpi_force_module.F90
(Generate patch)

Comparing trunk/mdtools/md_code/mpi_force_module.F90 (file contents):
Revision 173 by chuckv, Fri Nov 8 20:05:44 2002 UTC vs.
Revision 174 by chuckv, Mon Nov 11 22:35:41 2002 UTC

# Line 81 | Line 81 | module mpi_module  
81   ! interface for gather scatter routines
82  
83    interface gather
84 +     module procedure gather_integer
85       module procedure gather_double
86       module procedure gather_double_dim
87    end interface
# Line 152 | Line 153 | contains
153    subroutine make_Force_Grid(status)
154      integer, intent(out) :: status ! status returns -1 if error
155      integer ::  nWorldProcs
156 <    integer ::  nColumnsMax
156 >    integer ::  nColumnsMax !Maximum number of columns
157    
158      integer :: rowIndex
159      integer :: columnIndex
# Line 204 | Line 205 | contains
205  
206  
207  
208 +  subroutine mpi()
209  
210  
211  
212 +  end subroutine mpi_init_Forces
213 +
214    !! subroutine to distribute column and row atom type info...
215  
216    subroutine mpi_handle_atypes(status)
# Line 371 | Line 375 | contains
375  
376    end subroutine unplan_gather_scatter
377  
378 +  subroutine gather_integer( sbuffer, rbuffer, this_plan, status)
379 +
380 +    type (gs_plan), intent(in) :: this_plan
381 +    integer, dimension(:), intent(in) :: sbuffer
382 +    integer, dimension(:), intent(in) :: rbuffer
383 +    integer :: noffset
384 +    integer, intent(out), optional :: status
385 +
386 +    if (present(status)) status = 0
387 +    noffset = this_plan%displs(this_plan%me)
388 +
389 +    call mpi_allgatherv(sbuffer,this_plan%n_datum, mpi_integer, &
390 +         rbuffer,this_plan%counts,this_plan%displs,mpi_integer, &
391 +         this_plan%comm, mpi_err)
392 +
393 +    if (mpi_err /= 0) then
394 +      if (present(status)) status  = -1
395 +    endif
396 +
397 +  end subroutine gather_double
398 +
399    subroutine gather_double( sbuffer, rbuffer, this_plan, status)
400  
401      type (gs_plan), intent(in) :: this_plan

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines