/[MITgcm]/MITgcm/pkg/flt/exch_recv_get_vec.F
ViewVC logotype

Diff of /MITgcm/pkg/flt/exch_recv_get_vec.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.3 by jmc, Sun Jan 4 00:58:23 2009 UTC revision 1.4 by jmc, Wed Jan 7 23:17:23 2009 UTC
# Line 9  C--   o EXCH_RL_RECV_GET_VEC_Y Line 9  C--   o EXCH_RL_RECV_GET_VEC_Y
9    
10  C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|  C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
11    
12        SUBROUTINE EXCH_RL_RECV_GET_VEC_X( arrayE, arrayW,        SUBROUTINE EXCH_RL_RECV_GET_VEC_X(
13       I            myd1, myThid )       U                        arrayE, arrayW,
14         I                        myd1, myThid )
15  C     /==========================================================\  C     /==========================================================\
16  C     | SUBROUTINE RECV_RL_GET_X                                 |  C     | SUBROUTINE RECV_RL_GET_X                                 |
17  C     | o "Send" or "put" X edges for RL array.                  |  C     | o "Send" or "put" X edges for RL array.                  |
# Line 50  C     theSize Line 51  C     theSize
51  C     westCommMode               - Working variables holding type  C     westCommMode               - Working variables holding type
52  C     eastCommMode                 of communication a particular  C     eastCommMode                 of communication a particular
53  C                                  tile face uses.  C                                  tile face uses.
54        INTEGER I        INTEGER bi, bj
55        INTEGER bi, bj, biW, bjW, biE, bjE  c     INTEGER biW, bjW, biE, bjE
56        INTEGER westCommMode        INTEGER westCommMode
57        INTEGER eastCommMode        INTEGER eastCommMode
58        INTEGER spinCount        INTEGER spinCount
# Line 76  C--   iii. Set data read flag + memory s Line 77  C--   iii. Set data read flag + memory s
77         DO bi=myBxLo(myThid),myBxHi(myThid)         DO bi=myBxLo(myThid),myBxHi(myThid)
78          westCommMode  = _tileCommModeW(bi,bj)          westCommMode  = _tileCommModeW(bi,bj)
79          eastCommMode  = _tileCommModeE(bi,bj)          eastCommMode  = _tileCommModeE(bi,bj)
80          biE =  _tileBiE(bi,bj)  c       biE =  _tileBiE(bi,bj)
81          bjE =  _tileBjE(bi,bj)  c       bjE =  _tileBjE(bi,bj)
82          biW =  _tileBiW(bi,bj)  c       biW =  _tileBiW(bi,bj)
83          bjW =  _tileBjW(bi,bj)  c       bjW =  _tileBjW(bi,bj)
84          IF ( westCommMode .EQ. COMM_MSG ) THEN          IF ( westCommMode .EQ. COMM_MSG ) THEN
85  #ifdef ALLOW_USE_MPI  #ifdef ALLOW_USE_MPI
86  #ifndef ALWAYS_USE_MPI  #ifndef ALWAYS_USE_MPI
# Line 173  C        Update statistics Line 174  C        Update statistics
174         ENDDO         ENDDO
175        ENDIF        ENDIF
176    
 C--   Read from the buffers  
       DO bj=myByLo(myThid),myByHi(myThid)  
        DO bi=myBxLo(myThid),myBxHi(myThid)  
   
         biE =  _tileBiE(bi,bj)  
         bjE =  _tileBjE(bi,bj)  
         biW =  _tileBiW(bi,bj)  
         bjW =  _tileBjW(bi,bj)  
         westCommMode = _tileCommModeW(bi,bj)  
         eastCommMode = _tileCommModeE(bi,bj)  
          IF ( eastCommMode .EQ. COMM_GET ) THEN  
           DO I=1,myd1  
              arrayE(I,bi,bj) = arrayW(I,biE,bjE)  
            ENDDO  
          ENDIF  
          IF ( westCommMode .EQ. COMM_GET ) THEN  
           DO I=1,myd1  
              arrayW(I,bi,bj) = arrayE(I,biW,bjW)  
           ENDDO  
          ENDIF  
   
        ENDDO  
       ENDDO  
   
177        RETURN        RETURN
178        END        END
179    
180  C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|  C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
181    
182        SUBROUTINE EXCH_RL_RECV_GET_VEC_Y( arrayN, arrayS,        SUBROUTINE EXCH_RL_RECV_GET_VEC_Y(
183       I            myd1, myThid )       U                        arrayN, arrayS,
184         I                        myd1, myThid )
185  C     /==========================================================\  C     /==========================================================\
186  C     | SUBROUTINE RECV_RL_GET_Y                                 |  C     | SUBROUTINE RECV_RL_GET_Y                                 |
187  C     | o "Send" or "put" Y edges for RL array.                  |  C     | o "Send" or "put" Y edges for RL array.                  |
# Line 242  C     theSize Line 220  C     theSize
220  C     southCommMode               - Working variables holding type  C     southCommMode               - Working variables holding type
221  C     northCommMode                 of communication a particular  C     northCommMode                 of communication a particular
222  C                                  tile face uses.  C                                  tile face uses.
223        INTEGER I        INTEGER bi, bj
224        INTEGER bi, bj, biS, bjS, biN, bjN  c     INTEGER biS, bjS, biN, bjN
225        INTEGER southCommMode        INTEGER southCommMode
226        INTEGER northCommMode        INTEGER northCommMode
227        INTEGER spinCount        INTEGER spinCount
# Line 268  C--   iii. Set data read flag + memory s Line 246  C--   iii. Set data read flag + memory s
246         DO bi=myBxLo(myThid),myBxHi(myThid)         DO bi=myBxLo(myThid),myBxHi(myThid)
247          southCommMode  = _tileCommModeS(bi,bj)          southCommMode  = _tileCommModeS(bi,bj)
248          northCommMode  = _tileCommModeN(bi,bj)          northCommMode  = _tileCommModeN(bi,bj)
249          biN =  _tileBiN(bi,bj)  c       biN =  _tileBiN(bi,bj)
250          bjN =  _tileBjN(bi,bj)  c       bjN =  _tileBjN(bi,bj)
251          biS =  _tileBiS(bi,bj)  c       biS =  _tileBiS(bi,bj)
252          bjS =  _tileBjS(bi,bj)  c       bjS =  _tileBjS(bi,bj)
253          IF ( southCommMode .EQ. COMM_MSG ) THEN          IF ( southCommMode .EQ. COMM_MSG ) THEN
254  #ifdef ALLOW_USE_MPI  #ifdef ALLOW_USE_MPI
255  #ifndef ALWAYS_USE_MPI  #ifndef ALWAYS_USE_MPI
# Line 356  C        Update statistics Line 334  C        Update statistics
334         ENDDO         ENDDO
335        ENDIF        ENDIF
336    
 C--   Read from the buffers  
       DO bj=myByLo(myThid),myByHi(myThid)  
        DO bi=myBxLo(myThid),myBxHi(myThid)  
   
         biN =  _tileBiN(bi,bj)  
         bjN =  _tileBjN(bi,bj)  
         biS =  _tileBiS(bi,bj)  
         bjS =  _tileBjS(bi,bj)  
         southCommMode = _tileCommModeS(bi,bj)  
         northCommMode = _tileCommModeN(bi,bj)  
          IF ( southCommMode .EQ. COMM_GET ) THEN  
           DO I=1,myd1  
              arrayN(I,bi,bj) = arrayS(I,biN,bjN)  
            ENDDO  
          ENDIF  
          IF ( southCommMode .EQ. COMM_GET ) THEN  
           DO I=1,myd1  
              arrayS(I,bi,bj) = arrayN(I,biS,bjS)  
           ENDDO  
          ENDIF  
   
        ENDDO  
       ENDDO  
   
337        RETURN        RETURN
338        END        END
   

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

  ViewVC Help
Powered by ViewVC 1.1.22