/[MITgcm]/MITgcm/eesupp/src/exch_uv_xyz_rx.template
ViewVC logotype

Annotation of /MITgcm/eesupp/src/exch_uv_xyz_rx.template

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


Revision 1.5 - (hide annotations) (download)
Tue Nov 16 17:21:40 2004 UTC (19 years, 6 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint57m_post, checkpoint57g_pre, checkpoint57s_post, checkpoint58b_post, checkpoint57b_post, checkpoint57g_post, checkpoint56b_post, checkpoint57y_post, checkpoint57r_post, checkpoint57d_post, checkpoint57i_post, checkpoint58, checkpoint57, checkpoint56, checkpoint58f_post, checkpoint57n_post, checkpoint58d_post, checkpoint58a_post, checkpoint57z_post, checkpoint58m_post, checkpoint57l_post, checkpoint57t_post, checkpoint57v_post, checkpoint57f_post, checkpoint57a_post, checkpoint57h_pre, checkpoint57h_post, checkpoint57y_pre, checkpoint57c_post, checkpoint58e_post, checkpoint57c_pre, checkpoint58n_post, checkpoint57e_post, checkpoint57p_post, checkpint57u_post, checkpoint57q_post, eckpoint57e_pre, checkpoint58k_post, checkpoint56a_post, checkpoint58l_post, checkpoint57h_done, checkpoint57j_post, checkpoint57f_pre, checkpoint58g_post, checkpoint58h_post, checkpoint56c_post, checkpoint58j_post, checkpoint57a_pre, checkpoint57o_post, checkpoint57k_post, checkpoint57w_post, checkpoint58i_post, checkpoint57x_post, checkpoint58c_post
Changes since 1.4: +17 -4 lines
call exch2 equivalent (within #ifdef ALLOW_EXCH2 / #endif)

1 jmc 1.5 C $Header: /u/gcmpack/MITgcm/pkg/exch2/exch_uv_xyz_rx.template,v 1.2 2004/04/05 15:27:06 edhill Exp $
2 cnh 1.3 C $Name: $
3 adcroft 1.2
4 jmc 1.5 #include "PACKAGES_CONFIG.h"
5 adcroft 1.2 #include "CPP_EEOPTIONS.h"
6    
7 cnh 1.3 CBOP
8    
9     C !ROUTINE: EXCH_UV_XYZ_RX
10    
11     C !INTERFACE:
12 adcroft 1.2 SUBROUTINE EXCH_UV_XYZ_RX(
13 jmc 1.5 U Uphi, Vphi,
14     I withSigns, myThid )
15 adcroft 1.2 IMPLICIT NONE
16 cnh 1.3 C !DESCRIPTION:
17     C *==========================================================*
18     C | SUBROUTINE EXCH_UV_XYZ_RX
19     C | o Handle exchanges for _RX, 3-dimensional vector arrays.
20     C *==========================================================*
21     C | Vector arrays need to be rotated and interchaged for
22     C | exchange operations on some grids. This driver routine
23     C | branches to support this.
24     C *==========================================================*
25 adcroft 1.2
26 cnh 1.3 C !USES:
27 adcroft 1.2 C === Global data ===
28     #include "SIZE.h"
29     #include "EEPARAMS.h"
30     #include "EESUPPORT.h"
31 edhill 1.4 #include "EXCH.h"
32 adcroft 1.2
33 cnh 1.3 C !INPUT/OUTPUT PARAMETERS:
34 adcroft 1.2 C === Routine arguments ===
35 cnh 1.3 C phi :: Array with overlap regions are to be exchanged
36 jmc 1.5 C Note - The interface to EXCH_RX assumes that
37 cnh 1.3 C the standard Fortran 77 sequence association rules
38     C apply.
39     C myThid :: My thread id.
40 adcroft 1.2 _RX Uphi(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
41     _RX Vphi(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
42     LOGICAL withSigns
43     INTEGER myThid
44    
45 cnh 1.3 C !LOCAL VARIABLES:
46 adcroft 1.2 C == Local variables ==
47 cnh 1.3 C OL[wens] :: Overlap extents in west, east, north, south.
48     C exchWidth[XY] :: Extent of regions that will be exchanged.
49 adcroft 1.2 INTEGER OLw, OLe, OLn, OLs, exchWidthX, exchWidthY, myNz
50 cnh 1.3
51     CEOP
52 jmc 1.5 #ifdef ALLOW_EXCH2
53     CALL EXCH2_UV_XYZ_RX(
54     U Uphi, Vphi,
55     I withSigns, myThid )
56     RETURN
57     #endif
58 adcroft 1.2
59     OLw = OLx
60     OLe = OLx
61     OLn = OLy
62     OLs = OLy
63     exchWidthX = OLx
64     exchWidthY = OLy
65     myNz = Nr
66     C ** NOTE ** The exchange routine we use here does not
67     C require the preceeding and following barriers.
68     C However, the slow, simple exchange interface
69     C that is calling it here is meant to ensure
70     C that threads are synchronised before exchanges
71     C begine.
72     IF (useCubedSphereExchange) THEN
73     CALL EXCH_UV_RX_CUBE( Uphi, Vphi, withSigns,
74     I OLw, OLe, OLs, OLn, myNz,
75     I exchWidthX, exchWidthY,
76     I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid )
77     ELSE
78     c CALL EXCH_RX( Uphi,
79     c I OLw, OLe, OLs, OLn, myNz,
80     c I exchWidthX, exchWidthY,
81     c I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid )
82     c CALL EXCH_RX( Vphi,
83     c I OLw, OLe, OLs, OLn, myNz,
84     c I exchWidthX, exchWidthY,
85     c I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid )
86     c_jmc: for JAM compatibility, replace the 2 CALLs above by the 2 CPP_MACROs:
87     _EXCH_XYZ_RX( Uphi, myThid )
88     _EXCH_XYZ_RX( Vphi, myThid )
89     ENDIF
90    
91     RETURN
92     END
93 jmc 1.5
94     C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
95    
96     CEH3 ;;; Local Variables: ***
97     CEH3 ;;; mode:fortran ***
98     CEH3 ;;; End: ***

  ViewVC Help
Powered by ViewVC 1.1.22