A routine to free the communicator represented by comm
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(comm_type), | intent(inout) | :: | comm |
Communicator object |
subroutine free_comm_type (comm)
implicit none
type(comm_type), intent(inout) :: comm !< Communicator object
#ifdef MPI
integer :: ierror
!$OMP MASTER
call time_message(.false., time_mp_other, ' MPI Overheads')
!$OMP END MASTER
call mpi_comm_free(comm%id,ierror)
!$OMP MASTER
call time_message(.false., time_mp_other, ' MPI Overheads')
!$OMP END MASTER
#endif
comm%id = mp_comm_null
comm%iproc = -1
comm%nproc = -1
comm%proc0 = .false.
end subroutine free_comm_type