MODULE YOMMASK

USE PARKIND1  ,ONLY : JPIM

IMPLICIT NONE

SAVE

! ----------------------------------------------------------------------

! Module for On demand Semi-Lagrangian Masks

! * LSLONDEM: T/F on-demand SL communications switched on/off
! * LSLONDEM_ACTIVE: T/F active/ not active on-demand SL communications
! * LNEW_MASK_SL: T if use the new mask MASK_SL2A
LOGICAL :: LSLONDEM
LOGICAL :: LSLONDEM_ACTIVE
LOGICAL :: LNEW_MASK_SL

! * MASK_SL1, MASK_SL2, MASK_SL2A, MASK_SL3: masks for on-demand SL comms.
INTEGER(KIND=JPIM),ALLOCATABLE :: MASK_SL1(:)
INTEGER(KIND=JPIM),ALLOCATABLE :: MASK_SL2(:)
INTEGER(KIND=JPIM),ALLOCATABLE :: MASK_SL2A(:)
INTEGER(KIND=JPIM),ALLOCATABLE :: MASK_SL3(:)
INTEGER(KIND=JPIM),ALLOCATABLE :: MASK_SL2T(:,:)
INTEGER(KIND=JPIM),ALLOCATABLE :: MASK_SL2AT(:,:)
INTEGER(KIND=JPIM),ALLOCATABLE :: MASK_SL3T(:,:)

! * NFIXSFLD: description of fixed fields (fields not sent/received)
!   in on-demand communications.
INTEGER(KIND=JPIM) :: NFIXSFLD(2) 

! * MFIELD_TYPE1: field type in on-demand SL communications
!   (1 for 32 pt stencil, 2 for 8 pt stencil)
! * MFIELD_TYPE15: trajectory version of MFIELD_TYPE1 for TL and AD.
INTEGER(KIND=JPIM),ALLOCATABLE :: MFIELD_TYPE1(:)
INTEGER(KIND=JPIM),ALLOCATABLE :: MFIELD_TYPE15(:)

! ----------------------------------------------------------------------

END MODULE YOMMASK

