Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(MappedVector2D), | intent(inout) | :: | this | |||
type(Mesh2D), | intent(inout) | :: | mesh |
subroutine SideExchange_MappedVector2D(this,mesh)
implicit none
class(MappedVector2D),intent(inout) :: this
type(Mesh2D),intent(inout) :: mesh
! Local
integer :: e1,e2,s1,s2,e2Global
integer :: flip,bcid
integer :: i1,i2,ivar,idir
integer :: neighborRank
integer :: offset
offset = mesh%decomp%offsetElem(mesh%decomp%rankid+1)
if(mesh%decomp%mpiEnabled) then
call this%MPIExchangeAsync(mesh)
endif
! Do the side exchange internal to this mpi process
call SideExchange_2D_gpu(this%extboundary_gpu, &
this%boundary_gpu,mesh%sideinfo_gpu,mesh%decomp%elemToRank_gpu, &
mesh%decomp%rankid,offset,this%interp%N,2*this%nvar,this%nelem)
if(mesh%decomp%mpiEnabled) then
call mesh%decomp%FinalizeMPIExchangeAsync()
! Apply side flips for data exchanged with MPI
call ApplyFlip_2D_gpu(this%extboundary_gpu,mesh%sideInfo_gpu, &
mesh%decomp%elemToRank_gpu,mesh%decomp%rankId, &
offset,this%interp%N,2*this%nVar,this%nElem)
endif
endsubroutine SideExchange_MappedVector2D