Reserve mesh%decomp's request scratch for the largest scalar exchange a set with nvar variables posts: 2*nvar messages per rank-remote conforming side, mortar sub-side or anisotropic mortar half. Rank-local; no communication.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(Mesh3D), | intent(inout) | :: | mesh | |||
| integer, | intent(in) | :: | nvar |
subroutine ReserveSetMessages(mesh,nvar)
!! Reserve mesh%decomp's request scratch for the largest scalar exchange a set with
!! nvar variables posts: 2*nvar messages per rank-remote conforming side, mortar
!! sub-side or anisotropic mortar half. Rank-local; no communication.
implicit none
type(Mesh3D),intent(inout) :: mesh
integer,intent(in) :: nvar
! Local
integer :: nRemote
nRemote = mesh%decomp%CountRemoteSides(mesh%sideInfo,mesh%nElem,6)
if(mesh%nMortars > 0) then
nRemote = max(nRemote,mesh%decomp%CountRemoteMortarSides(mesh%mortarInfo,mesh%nMortars,4))
endif
if(mesh%nAnisoMortars > 0) then
nRemote = max(nRemote, &
mesh%decomp%CountRemoteMortarSides(mesh%anisoMortarInfo,mesh%nAnisoMortars,2))
endif
call mesh%decomp%ReserveMessages(2*nvar*nRemote)
endsubroutine ReserveSetMessages