tem_comm_destroy Subroutine

public subroutine tem_comm_destroy(me, commPattern)

Arguments

Type IntentOptional Attributes Name
type(tem_communication_type), intent(inout) :: me

communication type to be destroyed

type(tem_commPattern_type), intent(in) :: commPattern

Communication pattern


Calls

proc~~tem_comm_destroy~~CallsGraph proc~tem_comm_destroy tem_comm_destroy interface~destroy~30 destroy proc~tem_comm_destroy->interface~destroy~30 proc~destroy_da_label destroy_da_label interface~destroy~30->proc~destroy_da_label

Source Code

  subroutine tem_comm_destroy( me, commPattern )
    ! -------------------------------------------------------------------------!
    !> communication type to be destroyed
    type(tem_communication_type), intent(inout) :: me
    !> Communication pattern
    type(tem_commPattern_type), intent(in) :: commPattern
    ! -------------------------------------------------------------------------!
    integer :: iProc
    ! -------------------------------------------------------------------------!

    do iProc = 1, me%nProcs
      call commPattern%finbuf_real( me%buf_real(iProc) )
      call commPattern%finbuf_long( me%buf_long(iProc) )
      call commPattern%finbuf_int(  me%buf_int(iProc)  )
    end do

    deallocate( me%buf_real )
    deallocate( me%buf_long )
    deallocate( me%buf_int  )

    deallocate( me%proc )
    deallocate( me%nElemsProc )
    do iProc = 1, me%nProcs
      call destroy( me%elemPos(iProc) )
    end do
    deallocate( me%elemPos )
    deallocate( me%rqHandle )

  end subroutine tem_comm_destroy