/[MITgcm]/MITgcm/model/src/do_the_model_io.F
ViewVC logotype

Contents of /MITgcm/model/src/do_the_model_io.F

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


Revision 1.32 - (show annotations) (download)
Thu Oct 9 04:19:18 2003 UTC (20 years, 7 months ago) by edhill
Branch: MAIN
CVS Tags: checkpoint51k_post, checkpoint51o_pre, checkpoint51l_post, checkpoint52, checkpoint51t_post, checkpoint51n_post, checkpoint51s_post, checkpoint51n_pre, checkpoint51l_pre, checkpoint51q_post, checkpoint51r_post, checkpoint51i_post, checkpoint51o_post, ecco_c52_e35, checkpoint51m_post, checkpoint51p_post, checkpoint51u_post
Branch point for: branch-nonh, tg2-branch, checkpoint51n_branch
Changes since 1.31: +5 -1 lines
 o first check-in for the "branch-genmake2" merge
 o verification suite as run on shelley (gcc 3.2.2):

Wed Oct  8 23:42:29 EDT 2003
                T           S           U           V
G D M    c        m  s        m  s        m  s        m  s
E p a R  g  m  m  e  .  m  m  e  .  m  m  e  .  m  m  e  .
N n k u  2  i  a  a  d  i  a  a  d  i  a  a  d  i  a  a  d
2 d e n  d  n  x  n  .  n  x  n  .  n  x  n  .  n  x  n  .

OPTFILE=NONE

Y Y Y Y 13 16 16 16  0 16 16 16 16 16 16 16 16 13 12  0  0 pass  adjustment.128x64x1
Y Y Y Y 16 16 16 16  0 16 16 16 16 16 16  0  0 16 16  0  0 pass  adjustment.cs-32x32x1
Y Y Y Y 16 16 16 16  0 16 16 16 16 16 16 22  0 16 16 22  0 pass  adjust_nlfs.cs-32x32x1
Y Y Y Y -- 13 13 16 16 13 13 13 13 16 16 16 16 16 16 16 16 N/O   advect_cs
Y Y Y Y -- 22 16 16 16 16 16 16 13 16 16 16 16 16 16 16 16 N/O   advect_xy
Y Y Y Y -- 13 16 13 16 16 16 16 16 16 16 22 16 16 16 16 16 N/O   advect_xz
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 pass  aim.5l_cs
Y Y Y Y 14 16 16 16 16 16 16 16 16 13 16 16 16 16 16 13 16 pass  aim.5l_Equatorial_Channel
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 13 16 16 13 13 16 pass  aim.5l_LatLon
Y Y Y Y 13 16 16 16 16 16 16 16 16 16 13 12 13 13 16 13 16 pass  exp0
Y Y Y Y 14 16 16 16 16 16 16 16 22 16 16 16 13 16 16 22 16 pass  exp1
Y Y Y Y 13 13 16 13 16 16 16 16 16 13 13 16 16 13 13 13 13 pass  exp2
Y Y Y Y 16 16 16 16 16 16 16 16 22 16 16 16 16 16 16 16 16 pass  exp4
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 22 16 16 16 22 16 pass  exp5
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 pass  front_relax
Y Y Y Y 14 16 16 13 13 16 16 13 13 16 13 13 16 12 13 13 16 pass  global_ocean.90x40x15
Y Y Y Y 10 16 16 13 13 16 13 16 16 13 13 13 13 16 16 13 16 FAIL  global_ocean.cs32x15
Y Y Y Y  6 11 12 13 13 12 13 16 13  9  9  9  9 10  9  9 11 FAIL  global_ocean_pressure
Y Y Y Y 14 16 16 13 16 16 16 13 13 13 13 13 16 12 16 13 16 pass  global_with_exf
Y Y Y Y 14 16 16 16 16 16 16 16 16 11 13 22 13 16 16  9 16 pass  hs94.128x64x5
Y Y Y Y 13 16 16 16 16 16 16 16 16 11 16 16 16 13 16 22 13 pass  hs94.1x64x5
Y Y Y Y 14 16 16 16 16 16 16 16 16 13 16 13 13 16 16 22 13 pass  hs94.cs-32x32x5
Y Y Y Y 10 10 16 13 13 16 16 16 22 16 13 13 13 13 13 22 13 FAIL  ideal_2D_oce
Y Y Y Y  8 16 16 16 16 16 16 16 16 13 13  8 16 16 16 16 16 FAIL  internal_wave
Y Y Y Y 14 16 16 16 16 16 16 16 16 13 13 22 13 13 13 22 16 pass  inverted_barometer
Y Y Y Y 12 16 16 16 16 16 16 16 16 16 13 12 13 13 13 13 13 FAIL  lab_sea
Y Y Y Y 11 16 16 16 16 16 16 16 13 13 13 12 13 16 13 12 13 FAIL  natl_box
Y Y Y Y 16 16 16 16 16 16 16 16 22 16 16 16 16 16 16 16 16 pass  plume_on_slope
Y Y Y Y 13 16 16 16 16 13 16 16 16 16 16 16 16 13 16 16 16 pass  solid-body.cs-32x32x1

1 C $Header: /u/u3/gcmpack/MITgcm/model/src/do_the_model_io.F,v 1.31.2.1 2003/10/02 18:10:45 edhill Exp $
2 C $Name: $
3
4 #include "PACKAGES_CONFIG.h"
5 #include "CPP_OPTIONS.h"
6
7 CBOP
8 C !ROUTINE: DO_THE_MODEL_IO
9 C !INTERFACE:
10 SUBROUTINE DO_THE_MODEL_IO(myCurrentTime, myIter, myThid)
11 C !DESCRIPTION: \bv
12 C *==========================================================*
13 C | SUBROUTINE DO_THE_MODEL_IO
14 C | o Controlling routine for IO in model main time-stepping
15 C | loop.
16 C *==========================================================*
17 C | Many systems do not have thread safe IO so it is easier
18 C | to lump everything together and do dumping of fields
19 C | and updating of forcing terms in a single place.
20 C | The approach to IO used here is that writes are only
21 C | performed by thread 1 and that a process only writes out
22 C | its data ( it does not know about anyone elses data!)
23 C | Reading on the other hand is assumed to be from a file
24 C | containing all the data for all the processes. Only the
25 C | portion of data of interest to this process is actually
26 C | loaded. To work well this assumes the existence of some
27 C | reliable tool to join datasets together at the end of a
28 C | run - see joinds.p
29 C *==========================================================*
30 C \ev
31
32 C !USES:
33 IMPLICIT NONE
34 C == Global variables ===
35 #include "SIZE.h"
36 #include "EEPARAMS.h"
37 #include "PARAMS.h"
38 #include "DYNVARS.h"
39 cswdblk --- add ---
40 #ifdef ALLOW_BULK_FORCE
41 #include "BULKF.h"
42 #include "FFIELDS.h"
43 #endif
44 cswdblk -- end add ---
45 cswdice -- add ---
46 #ifdef ALLOW_THERM_SEAICE
47 #include "ICE.h"
48 #include "ICE_DIAGS.h"
49 #endif
50 cswdice -- end add ---
51
52
53
54 LOGICAL DIFFERENT_MULTIPLE
55 EXTERNAL DIFFERENT_MULTIPLE
56
57 C !INPUT/OUTPUT PARAMETERS:
58 C == Routine arguments ==
59 C myThid - Thread number for this instance of the routine.
60 C myIter - Iteration number
61 C myCurrentTime - Current time of simulation ( s )
62 INTEGER myThid
63 INTEGER myIter
64 _RL myCurrentTime
65
66 CEOP
67
68 C-- Generaly only thread 1 does IO here. It can not start until
69 C-- all threads fields are ready.
70 IF (
71 & DIFFERENT_MULTIPLE(dumpFreq,myCurrentTime,
72 & myCurrentTime-deltaTClock)
73 & ) THEN
74
75 _BARRIER
76
77 IF (debugMode) THEN
78 C-- Write "text-plots" of certain fields
79 CALL PLOT_FIELD_XYZRL( uVel , 'Current uVel ' ,
80 & Nr, myIter, myThid )
81 CALL PLOT_FIELD_XYZRL( vVel , 'Current vVel ' ,
82 & Nr, myIter, myThid )
83 CALL PLOT_FIELD_XYZRL( theta, 'Current theta ' ,
84 & Nr, myIter, myThid )
85 CALL PLOT_FIELD_XYRL( etaN , 'Current etaN ' ,
86 & myIter, myThid )
87 ENDIF
88
89 ENDIF
90
91 C-- Write model state to binary file
92 CALL WRITE_STATE( myCurrentTime, myIter, myThid )
93
94 #ifdef ALLOW_TIMEAVE
95 C-- Do time averages
96 ceh3 should this have an IF ( useTIMEAVE ) THEN
97 IF (taveFreq.GT.0.) THEN
98 CALL TIMEAVE_STATV_WRITE( myCurrentTime, myIter, myThid )
99 cswdptr -- add ---
100 #ifdef ALLOW_PTRACERS
101 ceh3 this needs an IF ( usePTRACERS ) THEN
102 CALL PTRACERS_STATV_WRITE( myCurrentTime, myIter, myThid )
103 #endif
104 cswdptr -- end add ---
105 ENDIF
106 #endif
107 #ifdef ALLOW_AIM
108 C-- Do AIM time averages
109 IF (useAIM)
110 & CALL AIM_WRITE_TAVE( myCurrentTime, myIter, myThid )
111 #endif
112 #ifdef ALLOW_LAND
113 C-- Do LAND time averages
114 IF (useLAND)
115 & CALL LAND_WRITE_TAVE( myCurrentTime, myIter, myThid )
116 #endif
117
118 #ifdef ALLOW_OBCS
119 IF (useOBCS)
120 & CALL OBCS_DIAGS( myCurrentTime, myIter, myThid )
121 #endif
122
123 #ifdef ALLOW_GMREDI
124 C-- Do KPP diagnostics.
125 IF (useGMRedi)
126 & CALL GMREDI_DIAGS( myCurrentTime, myIter, myThid )
127 #endif
128
129 #ifdef ALLOW_KPP
130 C-- Do KPP diagnostics.
131 IF (useKPP)
132 & CALL KPP_DO_DIAGS( myCurrentTime, myIter, myThid )
133 #endif
134
135 #ifdef ALLOW_SBO
136 C-- Do SBO diagnostics.
137 IF (useSBO) THEN
138 CALL SBO_CALC ( myCurrentTime, myIter, myThid )
139 CALL SBO_DIAGS( myCurrentTime, myIter, myThid )
140 ENDIF
141 #endif
142
143 cswdblk --- add ---
144 #ifdef ALLOW_BULK_FORCE
145 C-- Do bulkf diagnostics.
146 IF (useBulkforce)
147 & CALL BULKF_DIAGS( myCurrentTime, myIter, myThid )
148 #endif
149 cswdblk -- end add ---
150
151 cswdice --- add ---
152 #ifdef ALLOW_THERM_SEAICE
153 C-- Do seaice diagnostics.
154 IF (useThermSeaice)
155 & CALL ICE_DIAGS( myCurrentTime, myIter, myThid )
156 #endif
157 cswdice -- end add ---
158
159 cswdptr --- add ---
160 #ifdef ALLOW_GCHEM
161 ceh3 ??? why is one package depending upon another here?
162 C-- Do ptracer diagnostics.
163 IF (usePTRACERS)
164 & CALL GCHEM_DIAGS( myCurrentTime, myIter, myThid )
165 #endif
166 cswdptr -- end add ---
167
168
169 RETURN
170 END
171

  ViewVC Help
Powered by ViewVC 1.1.22