|
||||
File indexing completed on 2018-03-02 18:37:54 UTC
view on githubraw file Latest commit add29e06 on 2018-01-31 20:35:05 UTC6d54cf9ca1 Ed H*0001 #include "AUTODIFF_OPTIONS.h" 2dcaa8b9a5 Patr*0002 0003 c ================================================================== 0004 c 0005 c adopen_adclose.F: Routines to handle the I/O of the TAMC generated 0006 c code. All files are direct access files. 0007 c Routines: 0008 c 0009 c o adopen - Open file (here a dummy routine). 0010 c o adclose - Close file (here a dummy routine). 0011 c 0012 c 0013 c The following input veriables are used throughout in the argument 0014 c lists: 0015 c 9274434acc Jean*0016 c name - character 2dcaa8b9a5 Patr*0017 c On entry, name is the extended tape name. 9274434acc Jean*0018 c len - integer 2dcaa8b9a5 Patr*0019 c On entry, len is the number of characters in name. 9274434acc Jean*0020 c tid - integer 2dcaa8b9a5 Patr*0021 c On entry, tid identifies the tape. 0022 c vid - integer 0023 c On entry, vid identifies the variable to be stored on 0024 c the tape. 9274434acc Jean*0025 c var - real array of dimension length 2dcaa8b9a5 Patr*0026 c On entry, var contains the values to be stored. 0027 c var must not be changed. 9274434acc Jean*0028 c size - integer 2dcaa8b9a5 Patr*0029 c On entry, size is the size in bytes of the type of 0030 c variable var. 9274434acc Jean*0031 c length - integer 2dcaa8b9a5 Patr*0032 c On entry, length is the dimension of the variable 0033 c stored on the tape. 9274434acc Jean*0034 c irec - integer 2dcaa8b9a5 Patr*0035 c On entry, irec is the record number to be written. 0036 c mythid - integer 0037 c On entry, mythid is the number of the thread or 0038 c instance of the program. 0039 c myiter - integer 0040 c On entry, myiter is the current iteration step during 0041 c the integration. 0042 c 0043 c For further details on this see the TAMC Users Manual, Appendix B, 0044 c User defined Storage Subroutines. 0045 c 0046 c TAMC does not provide the two leading arguments mythid and myiter 0047 c when compiling the MITgcmUV code. Instead the is a sed script avail- 0048 c able that does change the TAMC-generated adjoint code. 0049 c 0050 c Only the master thread is allowed to write data and only gobal 0051 c model arrays are allowed to be written be the subsequent routines. 0052 c Tiled data are to be stored in common blocks. This implies that at 0053 c least a two level checkpointing for the adjoint code has to be 0054 c available. 0055 c 0056 c ================================================================== 0057 0058 d151781088 Patr*0059 CBOP 0060 C !ROUTINE: adopen 0061 C !INTERFACE: 2dcaa8b9a5 Patr*0062 subroutine adopen( 0063 I mythid, 0064 cph( 0065 cph I myiter, 0066 cph) 0067 I name, 0068 I len, 0069 I tid, 0070 I vid, 0071 I size, 0072 I length 0073 & ) 0074 d151781088 Patr*0075 C !DESCRIPTION: \bv 2dcaa8b9a5 Patr*0076 c ================================================================== 0077 c SUBROUTINE adopen 0078 c ================================================================== 0079 c o Dummy routine expected to be available by TAMC I/O. 0080 c This routine is simply a dummy routine expected to be available by 0081 c the Tangent Linear and Adjoint Model Compiler(TAMC). Files are 0082 c opened and closed by the routines that are called by *adread* and 0083 c *adwrite*. 0084 c started: Christian Eckert eckert@mit.edu 30-Jun-1999 0085 c ================================================================== 0086 c SUBROUTINE adopen 0087 c ================================================================== d151781088 Patr*0088 C \ev 2dcaa8b9a5 Patr*0089 d151781088 Patr*0090 C !USES: 2dcaa8b9a5 Patr*0091 implicit none 0092 0093 c == global variables == 0094 d151781088 Patr*0095 C !INPUT/OUTPUT PARAMETERS: 2dcaa8b9a5 Patr*0096 c == routine arguments == d151781088 Patr*0097 c name - extended tape name. 0098 c len - number of characters in name. 0099 c tid - tape identifier. 0100 c vid - identifies the variable to be stored on tape. 0101 c size - size in bytes of the type of variable var. 0102 c length - dimension of the variable stored on the tape. 0103 c mythid - number of the thread or instance of the program. 2dcaa8b9a5 Patr*0104 0105 integer mythid 0106 cph( 0107 cph integer myiter 0108 cph) 0109 character*(*) name 0110 integer len 0111 integer tid 0112 integer vid 0113 integer size 0114 integer length 0115 d151781088 Patr*0116 C !LOCAL VARIABLES: 2dcaa8b9a5 Patr*0117 c == local variables == 0118 0119 c == end of interface == d151781088 Patr*0120 CEOP 2dcaa8b9a5 Patr*0121 0122 return 0123 end 0124 0125 d151781088 Patr*0126 CBOP 0127 C !ROUTINE: adclose 0128 C !INTERFACE: 2dcaa8b9a5 Patr*0129 subroutine adclose( 0130 I mythid, 0131 cph( 0132 cph I myiter, 0133 cph) 0134 I name, 0135 I len, 0136 I tid, 0137 I vid, 0138 I size, 0139 I length 0140 & ) 0141 0142 d151781088 Patr*0143 C !DESCRIPTION: \bv 2dcaa8b9a5 Patr*0144 c ================================================================== 0145 c SUBROUTINE adclose 0146 c ================================================================== 0147 c o Dummy routine expected to be available by TAMC I/O. 0148 c This routine is simply a dummy routine expected to be available by 0149 c the Tangent Linear and Adjoint Model Compiler(TAMC). Files are 0150 c opened and closed by the routines that are called by *adread* and 0151 c *adwrite*. 0152 c started: Christian Eckert eckert@mit.edu 30-Jun-1999 0153 c ================================================================== 0154 c SUBROUTINE adclose 0155 c ================================================================== d151781088 Patr*0156 C \ev 2dcaa8b9a5 Patr*0157 d151781088 Patr*0158 C !USES: 2dcaa8b9a5 Patr*0159 implicit none 0160 0161 c == global variables == 0162 d151781088 Patr*0163 C !INPUT/OUTPUT PARAMETERS: 2dcaa8b9a5 Patr*0164 c == routine arguments == d151781088 Patr*0165 c name - extended tape name. 0166 c len - number of characters in name. 0167 c tid - tape identifier. 0168 c vid - identifies the variable to be stored on tape. 0169 c size - size in bytes of the type of variable var. 0170 c length - dimension of the variable stored on the tape. 0171 c mythid - number of the thread or instance of the program. 2dcaa8b9a5 Patr*0172 0173 integer mythid 0174 cph( 0175 cph integer myiter 0176 cph) 0177 character*(*) name 0178 integer len 0179 integer tid 0180 integer vid 0181 integer size 0182 integer length 0183 d151781088 Patr*0184 C !LOCAL VARIABLES: 2dcaa8b9a5 Patr*0185 c == local variables == 0186 0187 c == end of interface == d151781088 Patr*0188 CEOP 2dcaa8b9a5 Patr*0189 0190 return 0191 end
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated from https://github.com/MITgcm/MITgcm by the 2.2.1-MITgcm-0.1 LXR engine. The LXR team |