Changeset 11071 for NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/BDY/bdydyn2d.F90
- Timestamp:
- 2019-06-04T14:58:06+02:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/src/OCE/BDY/bdydyn2d.F90
r11067 r11071 51 51 !! 52 52 INTEGER :: ib_bdy ! Loop counter 53 LOGICAL, DIMENSION(4) :: l send2, lrecv2, lsend3,lrecv3 ! indicate how communications are to be carried out53 LOGICAL, DIMENSION(4) :: llsend2, llrecv2, llsend3, llrecv3 ! indicate how communications are to be carried out 54 54 55 55 DO ib_bdy=1, nb_bdy … … 72 72 ENDDO 73 73 ! 74 l send2(:) = .false.75 l recv2(:) = .false.76 l send3(:) = .false.77 l recv3(:) = .false.74 llsend2(:) = .false. 75 llrecv2(:) = .false. 76 llsend3(:) = .false. 77 llrecv3(:) = .false. 78 78 DO ib_bdy=1, nb_bdy 79 79 SELECT CASE( cn_dyn2d(ib_bdy) ) 80 80 CASE('flather') 81 lsend2(:) = lsend2(:) .OR. lsend_bdy(ib_bdy,2,:) ! to every bdy neighbour, U points 82 lrecv2(:) = lrecv2(:) .OR. lrecv_bdy(ib_bdy,2,:) ! from every bdy neighbour, U points 83 lsend3(:) = lsend3(:) .OR. lsend_bdy(ib_bdy,3,:) ! to every bdy neighbour, V points 84 lrecv3(:) = lrecv3(:) .OR. lrecv_bdy(ib_bdy,3,:) ! from every bdy neighbour, V points 85 CASE('orlanski') 86 lsend2(:) = lsend2(:) .OR. lsend_bdy(ib_bdy,2,:) ! to every bdy neighbour, U points 87 lrecv2(:) = lrecv2(:) .OR. lrecv_bdy(ib_bdy,2,:) ! from every bdy neighbour, U points 88 lsend3(:) = lsend3(:) .OR. lsend_bdy(ib_bdy,3,:) ! to every bdy neighbour, V points 89 lrecv3(:) = lrecv3(:) .OR. lrecv_bdy(ib_bdy,3,:) ! from every bdy neighbour, V points 90 CASE('orlanski_npo') 91 lsend2(:) = lsend2(:) .OR. lsend_bdy(ib_bdy,2,:) ! to every bdy neighbour, U points 92 lrecv2(:) = lrecv2(:) .OR. lrecv_bdy(ib_bdy,2,:) ! from every bdy neighbour, U points 93 lsend3(:) = lsend3(:) .OR. lsend_bdy(ib_bdy,3,:) ! to every bdy neighbour, V points 94 lrecv3(:) = lrecv3(:) .OR. lrecv_bdy(ib_bdy,3,:) ! from every bdy neighbour, V points 81 llsend2(1:2) = llsend2(1:2) .OR. lsend_bdyint(ib_bdy,2,1:2) ! west/east, U points 82 llsend2(1) = llsend2(1) .OR. lsend_bdyext(ib_bdy,2,1) ! neighbour might search point towards bdy on its east 83 llrecv2(1:2) = llrecv2(1:2) .OR. lrecv_bdyint(ib_bdy,2,1:2) ! west/east, U points 84 llrecv2(2) = llrecv2(2) .OR. lrecv_bdyext(ib_bdy,2,2) ! might search point towards bdy on the east 85 llsend3(3:4) = llsend3(3:4) .OR. lsend_bdyint(ib_bdy,3,3:4) ! north/south, V points 86 llsend3(3) = llsend3(3) .OR. lsend_bdyext(ib_bdy,3,3) ! neighbour might search point towards bdy on its north 87 llrecv3(3:4) = llrecv3(3:4) .OR. lrecv_bdyint(ib_bdy,3,3:4) ! north/south, V points 88 llrecv3(4) = llrecv3(4) .OR. lrecv_bdyext(ib_bdy,3,4) ! might search point towards bdy on the north 89 CASE('orlanski', 'orlanski_npo') 90 llsend2(:) = llsend2(:) .OR. lsend_bdy(ib_bdy,2,:) ! possibly every direction, U points 91 llrecv2(:) = llrecv2(:) .OR. lrecv_bdy(ib_bdy,2,:) ! possibly every direction, U points 92 llsend3(:) = llsend3(:) .OR. lsend_bdy(ib_bdy,3,:) ! possibly every direction, V points 93 llrecv3(:) = llrecv3(:) .OR. lrecv_bdy(ib_bdy,3,:) ! possibly every direction, V points 95 94 END SELECT 96 95 END DO 97 IF( ANY(l send2) .OR. ANY(lrecv2) ) THEN ! if need to send/recv in at least one direction98 CALL lbc_bdy_lnk( 'bdydyn2d', l send2,lrecv2, pua2d, 'U', -1. )96 IF( ANY(llsend2) .OR. ANY(llrecv2) ) THEN ! if need to send/recv in at least one direction 97 CALL lbc_bdy_lnk( 'bdydyn2d', llsend2, llrecv2, pua2d, 'U', -1. ) 99 98 END IF 100 IF( ANY(l send3) .OR. ANY(lrecv3) ) THEN ! if need to send/recv in at least one direction101 CALL lbc_bdy_lnk( 'bdydyn2d', l send3,lrecv3, pva2d, 'V', -1. )99 IF( ANY(llsend3) .OR. ANY(llrecv3) ) THEN ! if need to send/recv in at least one direction 100 CALL lbc_bdy_lnk( 'bdydyn2d', llsend3, llrecv3, pva2d, 'V', -1. ) 102 101 END IF 103 102 ! … … 197 196 ENDIF 198 197 END DO 199 200 198 ! 201 199 igrd = 2 ! Flather bc on u-velocity; … … 284 282 !! 285 283 INTEGER :: ib_bdy ! bdy index 286 LOGICAL, DIMENSION(4) :: l send1,lrecv1 ! indicate how communications are to be carried out287 !!---------------------------------------------------------------------- 288 l send1(:) = .false.289 l recv1(:) = .false.284 LOGICAL, DIMENSION(4) :: llsend1, llrecv1 ! indicate how communications are to be carried out 285 !!---------------------------------------------------------------------- 286 llsend1(:) = .false. 287 llrecv1(:) = .false. 290 288 DO ib_bdy = 1, nb_bdy 291 289 CALL bdy_nmn( idx_bdy(ib_bdy), 1, zssh ) ! zssh is masked 292 l send1(:) = lsend1(:) .OR. lsend_bdy(ib_bdy,1,:) ! to every bdy neighbour, T points293 l recv1(:) = lrecv1(:) .OR. lrecv_bdy(ib_bdy,1,:) ! from every bdy neighbour, T points294 END DO 295 IF( ANY(l send1) .OR. ANY(lrecv1) ) THEN ! if need to send/recv in at least one direction296 CALL lbc_bdy_lnk( 'bdydyn2d', l send1,lrecv1, zssh(:,:,1), 'T', 1. )290 llsend1(:) = llsend1(:) .OR. lsend_bdyint(ib_bdy,1,:) ! possibly every direction, T points 291 llrecv1(:) = llrecv1(:) .OR. lrecv_bdyint(ib_bdy,1,:) ! possibly every direction, T points 292 END DO 293 IF( ANY(llsend1) .OR. ANY(llrecv1) ) THEN ! if need to send/recv in at least one direction 294 CALL lbc_bdy_lnk( 'bdydyn2d', llsend1, llrecv1, zssh(:,:,1), 'T', 1. ) 297 295 END IF 298 296 !
Note: See TracChangeset
for help on using the changeset viewer.