1 !***********************************************************************
2 !* GNU Lesser General Public License
4 !* This file
is part of the GFDL Flexible Modeling System (FMS).
6 !* FMS
is free software: you can redistribute it and/or modify it under
7 !* the terms of the GNU Lesser General Public License as published by
8 !* the Free Software Foundation, either
version 3 of the License, or (at
9 !* your option) any later
version.
11 !* FMS
is distributed in the hope that it
will be useful, but WITHOUT
12 !* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 !* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
16 !* You should have
received a copy of the GNU Lesser General Public
17 !* License along with FMS. If
not, see <http:
18 !***********************************************************************
22 !>Write
out metadata and data
for axes and
fields to
a restart file
23 !!associated with an unstructured mpp domain.
24 subroutine fms_io_unstructured_save_restart(fileObj, &
31 type(restart_file_type),intent(inout),target :: fileObj !<A restart
object.
32 character(
len=*),intent(in),optional :: time_stamp !<A
time stamp
for the file.
33 character(
len=*),intent(in),optional :: directory !<The directory where the restart file lives.
34 logical(
INT_KIND),intent(in),optional :: append !<Flag telling whether to append to or overwrite the restart file.
40 ! routine writes both meta data and
field data.
42 !If append
is present and append=.true.:
45 !
time_level must also be present and it must be >= 0.0
49 ! A
new file
is opened and only the meta data
is written.
51 !If append
is present and append=.false.:
52 ! Behaves the same was as
if it were
not present. That
is, meta data
is 56 type(domainUG),pointer :: domain !<A pointer to an unstructured mpp domain.
57 integer(
INT_KIND) :: mpp_action !<Parameter specifying how the file
will be acted on (overwritten or appended to).
58 logical(
INT_KIND) :: write_meta_data !<Flag telling whether or
not metadata
will be written to the restart file.
59 logical(
INT_KIND) :: write_field_data !<Flag telling whether or
not field data
will be written to the restart file.
60 character(
len=128) :: dir !<Directory where the restart file lives.
61 character(
len=80) :: restartname !<The
name of the restart file.
62 character(
len=256) :: restartpath !<The restart file path (dir/file).
64 type(ax_type),pointer :: axis !<A pointer to an fms_io_axis_type.
65 type(axistype) :: x_axis !<An mpp_io_axis_type, used to write the x-axis to the restart file.
66 logical(
INT_KIND) :: x_axis_defined !<Flag telling whether or
not a x-axis has been define for the inputted restart object.
67 type(axistype) :: y_axis !<An mpp_io_axis_type, used to write the y-axis to the restart file.
68 logical(
INT_KIND) :: y_axis_defined !<Flag telling whether or
not a y-axis has been define for the inputted restart object.
69 type(axistype) :: z_axis !<An mpp_io_axis_type, used to write the z-axis to the restart file.
70 logical(
INT_KIND) :: z_axis_defined !<Flag telling whether or
not a z-axis has been define for the inputted restart object.
71 type(axistype) :: cc_axis !<An mpp_io_axis_type, used to write the
cc-axis (???) to the restart file.
72 logical(
INT_KIND) :: cc_axis_defined !<Flag telling whether or
not a cc-axis (???) has been define for the inputted restart object.
73 type(axistype) :: c_axis !<An mpp_io_axis_type, used to write the compressed
c-axis (???) to the restart file.
74 logical(
INT_KIND) :: c_axis_defined !<Flag telling whether or
not a compressed
c-axis (???) has been define for the inputted restart object.
75 type(axistype) :: h_axis !<An mpp_io_axis_type, used to write the compressed h-axis (???) to the restart file.
76 logical(
INT_KIND) :: h_axis_defined !<Flag telling whether or
not a compressed h-axis (???) has been define for the inputted restart object.
77 type(axistype) :: t_axis !<An mpp_io_axis_type, used to write the
t-axis to the restart file.
78 type(var_type),pointer :: cur_var !<A pointer to an fms_io_field_type.
81 integer(
INT_KIND) :: cpack !<(Number of bits in
a real(8))/(Number of bits in
a real)
83 real :: tlev !<Time value for
a time level (do
not specify
a kind value).
91 !Make sure at least
one field was registered to the restart object.
92 if (.
not. associated(fileObj%var)) then
94 "fms_io_unstructured_save_restart:" &
98 !If all
fields in the file are read only, then simply return without
99 !writing any data to the restart file. If the restart file does
not yet
100 !exist, it
is not created.
105 !Make sure that at least
one axis was registered to the restart object.
108 "fms_io_unstructured_save_restart: there are no" &
112 !Make sure that all registered
axes are associated with the same
113 !unstructured domain.
116 if (
j .
eq. CIDX .or.
j .
eq. HIDX .or.
j .
eq. UIDX) then
117 if (allocated(fileObj%
axes(
j)%idx)) then
118 if (.
not. associated(fileObj%
axes(
j)%domain_ug)) then
120 "fms_io_unstructured_save_restart:" &
126 if (associated(domain)) then
127 if (.
not. (domain .EQ. fileObj%
axes(
j)%domain_ug)) then
129 "fms_io_unstructured_save_restart:" &
135 domain => fileObj%
axes(
j)%domain_ug
139 if (associated(fileObj%
axes(
j)%data)) then
140 if (.
not. associated(fileObj%
axes(
j)%domain_ug)) then
142 "fms_io_unstructured_save_restart:" &
148 if (associated(domain)) then
149 if (.
not. (domain .EQ. fileObj%
axes(
j)%domain_ug)) then
151 "fms_io_unstructured_save_restart:" &
157 domain => fileObj%
axes(
j)%domain_ug
163 !Make sure that all registered
fields are associated with the same
164 !unstructured domain that all
axes were registered with.
165 do
j = 1,fileObj%
nvar 166 if (.
not. associated(fileObj%var(
j)%domain_ug)) then
168 "fms_io_unstructured_save_restart:" &
174 if (.
not. (domain .EQ. fileObj%var(
j)%domain_ug)) then
176 "fms_io_unstructured_save_restart:" &
185 !If necessary, make sure
a valid
set of optional arguments was provided.
186 if (present(append)) then
189 "fms_io_unstructured_save_compressed_restart:" &
195 !Determine whether or
not metadata
will be written to the restart file. If
196 !
no optional arguments are specified, metadata
will be written to the file,
197 !with any old data overwritten. If the optional append flag
is true, then
198 !it
is assumed that the metadata already exists in the file, and thus
199 !metadata
will not be written to the file.
200 mpp_action = MPP_OVERWR
201 write_meta_data = .
true.
202 if (present(append)) then
204 mpp_action = MPP_APPEND
205 write_meta_data = .
false.
208 "fms_io_unstructured_save_restart:" &
216 !Determine whether or
not field data
will be written to the restart file.
217 !Field data
will be written to the restart file unless
a negative
219 write_field_data = .
true.
222 write_field_data = .
false.
226 !Set the directory where the restart file lives. This defaults to
229 if (present(directory)) then
230 dir = trim(directory)
233 !Set the
name of the restart file excluding its path.
235 restartname = trim(fileObj%
name)
237 if (present(time_stamp)) then
238 if (len_trim(restartname) + len_trim(time_stamp) .gt. 79) then
240 "fms_io_unstructured_save_restart:" &
245 restartname = trim(time_stamp)
249 !Set the
name of the restart file including the path to it.
250 if (len_trim(dir) .gt. 0) then
251 restartpath = trim(dir)
253 restartpath = trim(restartname)
256 !Open the restart file.
257 call mpp_open(funit, &
261 is_root_pe=fileObj%is_root_pe, &
267 if (write_meta_data) then
269 !If it
is registered, then write
out the metadata for the x-axis
270 !to the restart file.
271 if (associated(fileObj%
axes(XIDX)%data)) then
272 axis => fileObj%
axes(XIDX)
273 call mpp_write_meta(funit, &
281 x_axis_defined = .
true.
283 x_axis_defined = .
false.
286 !If it
is registered, then write
out the metadata for the y-axis
287 !to the restart file.
288 if (associated(fileObj%
axes(YIDX)%data)) then
289 axis => fileObj%
axes(YIDX)
290 call mpp_write_meta(funit, &
298 y_axis_defined = .
true.
300 y_axis_defined = .
false.
303 !If it
is registered, then write
out the metadata for the z-axis
304 !to the restart file.
305 if (associated(fileObj%
axes(ZIDX)%data)) then
306 axis => fileObj%
axes(ZIDX)
307 call mpp_write_meta(funit, &
315 z_axis_defined = .
true.
317 z_axis_defined = .
false.
320 !If it
is registered, then write
out the metadata for the
cc-axis (???)
321 !to the restart file.
322 if (associated(fileObj%
axes(CCIDX)%data)) then
323 axis => fileObj%
axes(CCIDX)
324 call mpp_write_meta(funit, &
332 cc_axis_defined = .
true.
334 cc_axis_defined = .
false.
337 !If it
is registered, then write
out the metadata for the compressed
338 !
c-axis to the restart file.
339 if (allocated(fileObj%
axes(CIDX)%idx)) then
340 axis => fileObj%
axes(CIDX)
341 call mpp_def_dim(funit, &
342 trim(axis%dimlen_name), &
344 trim(axis%dimlen_lname), &
345 (/(
i,
i=1,axis%dimlen)/))
346 call mpp_write_meta(funit, &
352 compressed=axis%compressed, &
355 c_axis_defined = .
true.
357 c_axis_defined = .
false.
360 !If it
is registered, then write
out the metadata for the compressed
361 !h-axis to the restart file.
362 if (allocated(fileObj%
axes(HIDX)%idx)) then
363 axis => fileObj%
axes(HIDX)
364 call mpp_def_dim(funit, &
365 trim(axis%dimlen_name), &
367 trim(axis%dimlen_lname), &
368 (/(
i,
i=1,axis%dimlen)/))
369 call mpp_write_meta(funit, &
375 compressed=axis%compressed, &
378 h_axis_defined = .
true.
380 h_axis_defined = .
false.
383 !Write
out the
time axis to the restart file.
384 if (associated(fileObj%
axes(TIDX)%data)) then
385 axis => fileObj%
axes(TIDX)
386 call mpp_write_meta(funit, &
390 longname=axis%longname, &
395 call mpp_write_meta(funit, &
403 !Loop through the
fields and write
out the metadata.
404 do
j = 1,fileObj%
nvar 406 !Point to the current
field.
407 cur_var => fileObj%var(
j)
410 if (cur_var%read_only) then
415 !Make sure the
field has
a valid number of
time levels.
416 if (cur_var%siz(4) .gt. 1 .and. cur_var%siz(4) .ne. &
417 fileObj%max_ntime) then
419 "fms_io_unstructured_save_restart: " &
426 !Determine the dimensions for the
field. For
a scalar
field foo,
427 !it
is assumed that foo = foo(
t). For non-scalar
fields,
time 433 num_var_axes = cur_var%
ndim 434 do
k = 1,cur_var%
ndim 435 select
case (cur_var%field_dimension_order(
k))
443 var_axes(
k) = cc_axis
450 "fms_io_unstructured_save_restart:" &
456 if (cur_var%siz(4) .
eq. fileObj%max_ntime) then
457 num_var_axes = num_var_axes + 1
458 var_axes(num_var_axes) = t_axis
462 !Get the
"pack size" for default real types, where
463 !
pack_size = (Number of bits in
a real(8))/(Number of bits in
a real).
467 !Fields with
integer(4) data are handled differently then real
469 allocate(check_val(
max(1,cur_var%siz(4))))
470 do
k = 1,cur_var%siz(4)
471 if (associated(fileObj%p0dr(
k,
j)%
p)) then
472 check_val(
k) = mpp_chksum(fileObj%p0dr(
k,
j)%
p, &
474 mask_val=cur_var%default_data)
475 elseif (associated(fileObj%p1dr(
k,
j)%
p)) then
476 check_val(
k) = mpp_chksum(fileObj%p1dr(
k,
j)%
p, &
477 mask_val=cur_var%default_data)
478 elseif (associated(fileObj%p2dr(
k,
j)%
p)) then
479 check_val(
k) = mpp_chksum(fileObj%p2dr(
k,
j)%
p, &
480 mask_val=cur_var%default_data)
481 elseif (associated(fileObj%p3dr(
k,
j)%
p)) then
482 check_val(
k) = mpp_chksum(fileObj%p3dr(
k,
j)%
p, &
483 mask_val=cur_var%default_data)
484 elseif (associated(fileObj%p0di(
k,
j)%
p)) then
487 elseif (associated(fileObj%p1di(
k,
j)%
p)) then
488 check_val(
k) = mpp_chksum(fileObj%p1di(
k,
j)%
p, &
489 mask_val=cur_var%default_data)
491 elseif (associated(fileObj%p2di(
k,
j)%
p)) then
492 check_val(
k) = mpp_chksum(fileObj%p2di(
k,
j)%
p, &
493 mask_val=cur_var%default_data)
495 elseif (associated(fileObj%p3di(
k,
j)%
p)) then
497 "fms_io_unstructured_save_restart:" &
504 "fms_io_unstructured_save_restart:" &
512 !Write
out the metadata from
a field. Check-sums are only written
513 !
if field data
is written to the restart file.
514 if (write_field_data) then ! Write checksums only
if valid
field data exists
515 call mpp_write_meta(funit, &
517 var_axes(1:num_var_axes), &
522 checksum=check_val, &
523 fill=cur_var%default_data)
525 call mpp_write_meta(funit, &
527 var_axes(1:num_var_axes), &
532 fill=cur_var%default_data)
534 deallocate(check_val)
538 !Write the axis data to the restart file.
539 if (x_axis_defined) then
540 call mpp_write(funit, &
543 if (y_axis_defined) then
544 call mpp_write(funit, &
547 if (c_axis_defined) then
548 call mpp_write(funit, &
551 if (h_axis_defined) then
552 call mpp_write(funit, &
555 if (cc_axis_defined) then
556 call mpp_write(funit, &
559 if (z_axis_defined) then
560 call mpp_write(funit, &
565 !Write
out field data to the restart file.
566 if (write_field_data) then
568 !Loop through all
time levels.
569 do
k = 1,fileObj%max_ntime
571 !Get the
time value for the
time level.
579 do
j = 1,fileObj%
nvar 581 !Point to the current
field.
582 cur_var => fileObj%var(
j)
585 if (cur_var%read_only) then
590 !Write
out the
field data to the file.
591 if (
k .le. cur_var%siz(4)) then
592 if (associated(fileObj%p0dr(
k,
j)%
p)) then
593 call mpp_write(funit, &
595 fileObj%p0dr(
k,
j)%
p, &
597 elseif (associated(fileObj%p1dr(
k,
j)%
p)) then
598 call mpp_io_unstructured_write(funit, &
601 fileObj%p1dr(
k,
j)%
p, &
602 fileObj%
axes(cur_var%field_dimension_order(1))%
nelems, &
604 default_data=cur_var%default_data)
605 elseif (associated(fileObj%p2dr(
k,
j)%
p)) then
606 call mpp_io_unstructured_write(funit, &
609 fileObj%p2dr(
k,
j)%
p, &
610 fileObj%
axes(cur_var%field_dimension_order(1))%
nelems, &
612 default_data=cur_var%default_data)
613 elseif (associated(fileObj%p3dr(
k,
j)%
p)) then
614 call mpp_io_unstructured_write(funit, &
617 fileObj%p3dr(
k,
j)%
p, &
618 fileObj%
axes(cur_var%field_dimension_order(1))%
nelems, &
620 default_data=cur_var%default_data)
621 elseif (associated(fileObj%p0di(
k,
j)%
p)) then
622 r0d = real(fileObj%p0di(
k,
j)%
p)
623 call mpp_write(funit, &
627 elseif (associated(fileObj%p1di(
k,
j)%
p)) then
628 allocate(r1d(
size(fileObj%p1di(
k,
j)%
p,1)))
629 r1d = real(fileObj%p1di(
k,
j)%
p)
630 call mpp_io_unstructured_write(funit, &
634 fileObj%
axes(cur_var%field_dimension_order(1))%
nelems, &
636 default_data=cur_var%default_data)
638 elseif (associated(fileObj%p2di(
k,
j)%
p)) then
639 allocate(r2d(
size(fileObj%p2di(
k,
j)%
p,1),
size(fileObj%p2di(
k,
j)%
p,2)))
640 r2d = real(fileObj%p2di(
k,
j)%
p)
641 call mpp_io_unstructured_write(funit, &
645 fileObj%
axes(cur_var%field_dimension_order(1))%
nelems, &
647 default_data=cur_var%default_data)
651 "fms_io_unstructured_save_restart:" &
663 !Close the restart file.
664 call mpp_close(funit)
666 !Nullify local pointers.
672 end subroutine fms_io_unstructured_save_restart
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! MPP_TRANSMIT !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! subroutine MPP_TRANSMIT_(put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, recv_request, send_request)!a message-passing routine intended to be reminiscent equally of both MPI and SHMEM!put_data and get_data are contiguous MPP_TYPE_ arrays!at each call, your put_data array is put to to_pe 's get_data! your get_data array is got from from_pe 's put_data!i.e we assume that typically(e.g updating halo regions) each PE performs a put _and_ a get!special PE designations:! NULL_PE:to disable a put or a get(e.g at boundaries)! ANY_PE:if remote PE for the put or get is to be unspecific! ALL_PES:broadcast and collect operations(collect not yet implemented)!ideally we would not pass length, but this f77-style call performs better(arrays passed by address, not descriptor)!further, this permits< length > contiguous words from an array of any rank to be passed(avoiding f90 rank conformance check)!caller is responsible for completion checks(mpp_sync_self) before and after integer, intent(in) ::put_len, to_pe, get_len, from_pe MPP_TYPE_, intent(in) ::put_data(*) MPP_TYPE_, intent(out) ::get_data(*) logical, intent(in), optional ::block integer, intent(in), optional ::tag integer, intent(out), optional ::recv_request, send_request logical ::block_comm integer ::i MPP_TYPE_, allocatable, save ::local_data(:) !local copy used by non-parallel code(no SHMEM or MPI) integer ::comm_tag integer ::rsize if(.NOT.module_is_initialized) call mpp_error(FATAL, 'MPP_TRANSMIT:You must first call mpp_init.') if(to_pe.EQ.NULL_PE .AND. from_pe.EQ.NULL_PE) return block_comm=.true. if(PRESENT(block)) block_comm=block if(debug) then call SYSTEM_CLOCK(tick) write(stdout_unit,'(a, i18, a, i6, a, 2i6, 2i8)')&'T=', tick, ' PE=', pe, ' MPP_TRANSMIT begin:to_pe, from_pe, put_len, get_len=', to_pe, from_pe, put_len, get_len end if comm_tag=DEFAULT_TAG if(present(tag)) comm_tag=tag!do put first and then get if(to_pe.GE.0 .AND. to_pe.LT.npes) then!use non-blocking sends if(debug .and.(current_clock.NE.0)) call SYSTEM_CLOCK(start_tick)!z1l:truly non-blocking send.! if(request(to_pe).NE.MPI_REQUEST_NULL) then !only one message from pe-> to_pe in queue *PE waiting for to_pe ! call error else get_len so only do gets but you cannot have a pure get with MPI call a get means do a wait to ensure put on remote PE is complete error call increase mpp_nml request_multiply call MPP_TRANSMIT get_len end if return end subroutine MPP_TRANSMIT_ ! MPP_BROADCAST ! subroutine but that doesn t allow !broadcast to a subset of PEs This version will
type(ext_fieldtype), dimension(:), pointer, save, private field
*f90 *************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************subroutine MPP_UPDATE_NEST_FINE_2D_(field, nest_domain, wbuffer, ebuffer, sbuffer, nbuffer, &flags, complete, position, extra_halo, name, tile_count) MPP_TYPE_, intent(in) ::field(:,:) type(nest_domain_type), intent(inout) ::nest_domain MPP_TYPE_, intent(inout) ::wbuffer(:,:) MPP_TYPE_, intent(inout) ::ebuffer(:,:) MPP_TYPE_, intent(inout) ::sbuffer(:,:) MPP_TYPE_, intent(inout) ::nbuffer(:,:) integer, intent(in), optional ::flags logical, intent(in), optional ::complete integer, intent(in), optional ::position integer, intent(in), optional ::extra_halo character(len= *), intent(in), optional ::name integer, intent(in), optional ::tile_count MPP_TYPE_ ::field3D(size(field, 1), size(field, 2), 1) MPP_TYPE_ ::wbuffer3D(size(wbuffer, 1), size(wbuffer, 2), 1) MPP_TYPE_ ::ebuffer3D(size(ebuffer, 1), size(ebuffer, 2), 1) MPP_TYPE_ ::sbuffer3D(size(sbuffer, 1), size(sbuffer, 2), 1) MPP_TYPE_ ::nbuffer3D(size(nbuffer, 1), size(nbuffer, 2), 1) pointer(ptr, field3D) pointer(ptr_w, wbuffer3D) pointer(ptr_e, ebuffer3D) pointer(ptr_s, sbuffer3D) pointer(ptr_n, nbuffer3D) ptr=LOC(field) ptr_w=LOC(wbuffer) ptr_e=LOC(ebuffer) ptr_s=LOC(sbuffer) ptr_n=LOC(nbuffer) call mpp_update_nest_fine(field3D, nest_domain, wbuffer3D, ebuffer3D, sbuffer3D, nbuffer3D, &flags, complete, position, extra_halo, name, tile_count) returnend subroutine MPP_UPDATE_NEST_FINE_2D_subroutine MPP_UPDATE_NEST_FINE_3D_(field, nest_domain, wbuffer, sbuffer, ebuffer, nbuffer, &flags, complete, position, extra_halo, name, tile_count) MPP_TYPE_, intent(in) ::field(:,:,:) type(nest_domain_type), intent(inout) ::nest_domain MPP_TYPE_, intent(inout) ::wbuffer(:,:,:) MPP_TYPE_, intent(inout) ::ebuffer(:,:,:) MPP_TYPE_, intent(inout) ::sbuffer(:,:,:) MPP_TYPE_, intent(inout) ::nbuffer(:,:,:) integer, intent(in), optional ::flags logical, intent(in), optional ::complete integer, intent(in), optional ::position integer, intent(in), optional ::extra_halo character(len= *), intent(in), optional ::name integer, intent(in), optional ::tile_count MPP_TYPE_ ::d_type type(nestSpec), pointer ::update=> set_mismatch integer ::tile update_position nbuffersz l_size integer
l_size ! loop over number of fields ke do je do i
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************subroutine READ_RECORD_CORE_(unit, field, nwords, data, start, axsiz) integer, intent(in) ::unit type(fieldtype), intent(in) ::field integer, intent(in) ::nwords MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in) ::start(:), axsiz(:) integer(SHORT_KIND) ::i2vals(nwords)!rab used in conjunction with transfer intrinsic to determine size of a variable integer(KIND=1) ::one_byte(8) integer ::word_sz!#ifdef __sgi integer(INT_KIND) ::ivals(nwords) real(FLOAT_KIND) ::rvals(nwords)!#else! integer ::ivals(nwords)! real ::rvals(nwords)!#endif real(DOUBLE_KIND) ::r8vals(nwords) pointer(ptr1, i2vals) pointer(ptr2, ivals) pointer(ptr3, rvals) pointer(ptr4, r8vals) if(mpp_io_stack_size< nwords) call mpp_io_set_stack_size(nwords) call mpp_error(FATAL, 'MPP_READ currently requires use_netCDF option') end subroutine READ_RECORD_CORE_ subroutine READ_RECORD_(unit, field, nwords, data, time_level, domain, position, tile_count, start_in, axsiz_in)!routine that is finally called by all mpp_read routines to perform the read!a non-netCDF record contains:! field ID! a set of 4 coordinates(is:ie, js:je) giving the data subdomain! a timelevel and a timestamp(=NULLTIME if field is static)! 3D real data(stored as 1D)!if you are using direct access I/O, the RECL argument to OPEN must be large enough for the above!in a global direct access file, record position on PE is given by %record.!Treatment of timestamp:! We assume that static fields have been passed without a timestamp.! Here that is converted into a timestamp of NULLTIME.! For non-netCDF fields, field is treated no differently, but is written! with a timestamp of NULLTIME. There is no check in the code to prevent! the user from repeatedly writing a static field. integer, intent(in) ::unit, nwords type(fieldtype), intent(in) ::field MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in), optional ::time_level type(domain2D), intent(in), optional ::domain integer, intent(in), optional ::position, tile_count integer, intent(in), optional ::start_in(:), axsiz_in(:) integer, dimension(size(field%axes(:))) ::start, axsiz integer ::tlevel !, subdomain(4) integer ::i, error, is, ie, js, je, isg, ieg, jsg, jeg type(domain2d), pointer ::io_domain=> unit
integer, parameter, public no
logical time_stamp_restart
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************subroutine MPP_WRITE_UNLIMITED_AXIS_1D_(unit, field, domain, data, nelems_io) integer, intent(in) ::unit type(fieldtype), intent(inout) ::field type(domain2D), intent(inout) ::domain MPP_TYPE_, intent(inout) ::data(:) integer, intent(in) ::nelems_io(:) ! number of compressed elements from each ! member of the io_domain. It MUST have the ! same order as the io_domain pelist. integer, allocatable ::pelist(:) integer ::i, j, nelems, npes type(domain2d), pointer ::io_domain=> allocatable
subroutine, public copy(self, rhs)
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! MPP_TRANSMIT !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! subroutine MPP_TRANSMIT_(put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, recv_request, send_request)!a message-passing routine intended to be reminiscent equally of both MPI and SHMEM!put_data and get_data are contiguous MPP_TYPE_ arrays!at each call, your put_data array is put to to_pe 's get_data! your get_data array is got from from_pe 's put_data!i.e we assume that typically(e.g updating halo regions) each PE performs a put _and_ a get!special PE designations:! NULL_PE:to disable a put or a get(e.g at boundaries)! ANY_PE:if remote PE for the put or get is to be unspecific! ALL_PES:broadcast and collect operations(collect not yet implemented)!ideally we would not pass length, but this f77-style call performs better(arrays passed by address, not descriptor)!further, this permits< length > contiguous words from an array of any rank to be passed(avoiding f90 rank conformance check)!caller is responsible for completion checks(mpp_sync_self) before and after integer, intent(in) ::put_len, to_pe, get_len, from_pe MPP_TYPE_, intent(in) ::put_data(*) MPP_TYPE_, intent(out) ::get_data(*) logical, intent(in), optional ::block integer, intent(in), optional ::tag integer, intent(out), optional ::recv_request, send_request logical ::block_comm integer ::i MPP_TYPE_, allocatable, save ::local_data(:) !local copy used by non-parallel code(no SHMEM or MPI) integer ::comm_tag integer ::rsize if(.NOT.module_is_initialized) call mpp_error(FATAL, 'MPP_TRANSMIT:You must first call mpp_init.') if(to_pe.EQ.NULL_PE .AND. from_pe.EQ.NULL_PE) return block_comm=.true. if(PRESENT(block)) block_comm=block if(debug) then call SYSTEM_CLOCK(tick) write(stdout_unit,'(a, i18, a, i6, a, 2i6, 2i8)')&'T=', tick, ' PE=', pe, ' MPP_TRANSMIT begin:to_pe, from_pe, put_len, get_len=', to_pe, from_pe, put_len, get_len end if comm_tag=DEFAULT_TAG if(present(tag)) comm_tag=tag!do put first and then get if(to_pe.GE.0 .AND. to_pe.LT.npes) then!use non-blocking sends if(debug .and.(current_clock.NE.0)) call SYSTEM_CLOCK(start_tick)!z1l:truly non-blocking send.! if(request(to_pe).NE.MPI_REQUEST_NULL) then !only one message from pe-> to_pe in queue *PE waiting for to_pe ! call error else get_len so only do gets but you cannot have a pure get with MPI call a get means do a wait to ensure put on remote PE is complete error call increase mpp_nml request_multiply call MPP_TRANSMIT end
integer(long), parameter true
type(field_mgr_type), dimension(max_fields), private fields
character(len=32) units
No description.
type(diag_axis_type), dimension(:), allocatable, save axes
real(r8), dimension(cast_m, cast_n) p
integer(long), parameter false
l_size ! loop over number of fields ke do j
integer, parameter, public nelems
logical function all_field_read_only(fileObj)
l_size ! loop over number of fields ke do je do ie to je n if(.NOT. d_comm%R_do_buf(list)) cycle from_pe
character(len=128) version
l_size ! loop over number of fields ke do je do ie to is
integer nvar
No description.
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! MPP_TRANSMIT !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! subroutine MPP_TRANSMIT_(put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, recv_request, send_request)!a message-passing routine intended to be reminiscent equally of both MPI and SHMEM!put_data and get_data are contiguous MPP_TYPE_ arrays!at each call, your put_data array is put to to_pe 's get_data! your get_data array is got from from_pe 's put_data!i.e we assume that typically(e.g updating halo regions) each PE performs a put _and_ a get!special PE designations:! NULL_PE:to disable a put or a get(e.g at boundaries)! ANY_PE:if remote PE for the put or get is to be unspecific! ALL_PES:broadcast and collect operations(collect not yet implemented)!ideally we would not pass length, but this f77-style call performs better(arrays passed by address, not descriptor)!further, this permits< length > contiguous words from an array of any rank to be passed(avoiding f90 rank conformance check)!caller is responsible for completion checks(mpp_sync_self) before and after integer, intent(in) ::put_len, to_pe, get_len, from_pe MPP_TYPE_, intent(in) ::put_data(*) MPP_TYPE_, intent(out) ::get_data(*) logical, intent(in), optional ::block integer, intent(in), optional ::tag integer, intent(out), optional ::recv_request, send_request logical ::block_comm integer ::i MPP_TYPE_, allocatable, save ::local_data(:) !local copy used by non-parallel code(no SHMEM or MPI) integer ::comm_tag integer ::rsize if(.NOT.module_is_initialized) call mpp_error(FATAL, 'MPP_TRANSMIT:You must first call mpp_init.') if(to_pe.EQ.NULL_PE .AND. from_pe.EQ.NULL_PE) return block_comm=.true. if(PRESENT(block)) block_comm=block if(debug) then call SYSTEM_CLOCK(tick) write(stdout_unit,'(a, i18, a, i6, a, 2i6, 2i8)')&'T=', tick, ' PE=', pe, ' MPP_TRANSMIT begin:to_pe, from_pe, put_len, get_len=', to_pe, from_pe, put_len, get_len end if comm_tag=DEFAULT_TAG if(present(tag)) comm_tag=tag!do put first and then get if(to_pe.GE.0 .AND. to_pe.LT.npes) then!use non-blocking sends if(debug .and.(current_clock.NE.0)) call SYSTEM_CLOCK(start_tick)!z1l:truly non-blocking send.! if(request(to_pe).NE.MPI_REQUEST_NULL) then !only one message from pe-> to_pe in queue *PE waiting for to_pe ! call error else get_len so only do gets but you cannot have a pure get with MPI call mpp_error(FATAL, 'MPP_TRANSMIT:you cannot transmit to ANY_PE using MPI.') else if(to_pe.NE.NULL_PE) then !no other valid cases except NULL_PE call mpp_error(FATAL
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************subroutine READ_RECORD_CORE_(unit, field, nwords, data, start, axsiz) integer, intent(in) ::unit type(fieldtype), intent(in) ::field integer, intent(in) ::nwords MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in) ::start(:), axsiz(:) integer(SHORT_KIND) ::i2vals(nwords)!rab used in conjunction with transfer intrinsic to determine size of a variable integer(KIND=1) ::one_byte(8) integer ::word_sz!#ifdef __sgi integer(INT_KIND) ::ivals(nwords) real(FLOAT_KIND) ::rvals(nwords)!#else! integer ::ivals(nwords)! real ::rvals(nwords)!#endif real(DOUBLE_KIND) ::r8vals(nwords) pointer(ptr1, i2vals) pointer(ptr2, ivals) pointer(ptr3, rvals) pointer(ptr4, r8vals) if(mpp_io_stack_size< nwords) call mpp_io_set_stack_size(nwords) call mpp_error(FATAL, 'MPP_READ currently requires use_netCDF option') end subroutine READ_RECORD_CORE_ subroutine READ_RECORD_(unit, field, nwords, data, time_level, domain, position, tile_count, start_in, axsiz_in)!routine that is finally called by all mpp_read routines to perform the read!a non-netCDF record contains:! field ID! a set of 4 coordinates(is:ie, js:je) giving the data subdomain! a timelevel and a timestamp(=NULLTIME if field is static)! 3D real data(stored as 1D)!if you are using direct access I/O, the RECL argument to OPEN must be large enough for the above!in a global direct access file, record position on PE is given by %record.!Treatment of timestamp:! We assume that static fields have been passed without a timestamp.! Here that is converted into a timestamp of NULLTIME.! For non-netCDF fields, field is treated no differently, but is written! with a timestamp of NULLTIME. There is no check in the code to prevent! the user from repeatedly writing a static field. integer, intent(in) ::unit, nwords type(fieldtype), intent(in) ::field MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in), optional ::time_level type(domain2D), intent(in), optional ::domain integer, intent(in), optional ::position, tile_count integer, intent(in), optional ::start_in(:), axsiz_in(:) integer, dimension(size(field%axes(:))) ::start, axsiz integer ::tlevel !, subdomain(4) integer ::i, error, is, ie, js, je, isg, ieg, jsg, jeg type(domain2d), pointer ::io_domain=> tlevel if(PRESENT(start_in) .AND. PRESENT(axsiz_in)) then if(size(start(! the data domain and compute domain must refer to the subdomain being passed ! In this case
subroutine calendar(year, month, day, hour)
real(double), parameter one
logical function received(this, seqno)
type(tms), dimension(nblks), private last
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************subroutine READ_RECORD_CORE_(unit, field, nwords, data, start, axsiz) integer, intent(in) ::unit type(fieldtype), intent(in) ::field integer, intent(in) ::nwords MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in) ::start(:), axsiz(:) integer(SHORT_KIND) ::i2vals(nwords)!rab used in conjunction with transfer intrinsic to determine size of a variable integer(KIND=1) ::one_byte(8) integer ::word_sz!#ifdef __sgi integer(INT_KIND) ::ivals(nwords) real(FLOAT_KIND) ::rvals(nwords)!#else! integer ::ivals(nwords)! real ::rvals(nwords)!#endif real(DOUBLE_KIND) ::r8vals(nwords) pointer(ptr1, i2vals) pointer(ptr2, ivals) pointer(ptr3, rvals) pointer(ptr4, r8vals) if(mpp_io_stack_size< nwords) call mpp_io_set_stack_size(nwords) call mpp_error(FATAL, 'MPP_READ currently requires use_netCDF option') end subroutine READ_RECORD_CORE_ subroutine READ_RECORD_(unit, field, nwords, data, time_level, domain, position, tile_count, start_in, axsiz_in)!routine that is finally called by all mpp_read routines to perform the read!a non-netCDF record contains:! field ID! a set of 4 coordinates(is:ie, js:je) giving the data subdomain! a timelevel and a timestamp(=NULLTIME if field is static)! 3D real data(stored as 1D)!if you are using direct access I/O, the RECL argument to OPEN must be large enough for the above!in a global direct access file, record position on PE is given by %record.!Treatment of timestamp:! We assume that static fields have been passed without a timestamp.! Here that is converted into a timestamp of NULLTIME.! For non-netCDF fields, field is treated no differently, but is written! with a timestamp of NULLTIME. There is no check in the code to prevent! the user from repeatedly writing a static field. integer, intent(in) ::unit, nwords type(fieldtype), intent(in) ::field MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in), optional ::time_level type(domain2D), intent(in), optional ::domain integer, intent(in), optional ::position, tile_count integer, intent(in), optional ::start_in(:), axsiz_in(:) integer, dimension(size(field%axes(:))) ::start, axsiz integer ::tlevel !, subdomain(4) integer ::i, error, is, ie, js, je, isg, ieg, jsg, jeg type(domain2d), pointer ::io_domain=> tlevel if(PRESENT(start_in) .AND. PRESENT(axsiz_in)) then if(size(start(! the data domain and compute domain must refer to the subdomain being passed ! In this ! since that attempts to gather all data on PE size(field%axes(:)) axsiz(i)
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! MPP_TRANSMIT !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! subroutine MPP_TRANSMIT_(put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, recv_request, send_request)!a message-passing routine intended to be reminiscent equally of both MPI and SHMEM!put_data and get_data are contiguous MPP_TYPE_ arrays!at each call, your put_data array is put to to_pe 's get_data! your get_data array is got from from_pe 's put_data!i.e we assume that typically(e.g updating halo regions) each PE performs a put _and_ a get!special PE designations:! NULL_PE:to disable a put or a get(e.g at boundaries)! ANY_PE:if remote PE for the put or get is to be unspecific! ALL_PES:broadcast and collect operations(collect not yet implemented)!ideally we would not pass length, but this f77-style call performs better(arrays passed by address, not descriptor)!further, this permits< length > contiguous words from an array of any rank to be passed(avoiding f90 rank conformance check)!caller is responsible for completion checks(mpp_sync_self) before and after integer, intent(in) ::put_len, to_pe, get_len, from_pe MPP_TYPE_, intent(in) ::put_data(*) MPP_TYPE_, intent(out) ::get_data(*) logical, intent(in), optional ::block integer, intent(in), optional ::tag integer, intent(out), optional ::recv_request, send_request logical ::block_comm integer ::i MPP_TYPE_, allocatable, save ::local_data(:) !local copy used by non-parallel code(no SHMEM or MPI) integer ::comm_tag integer ::rsize if(.NOT.module_is_initialized) call mpp_error(FATAL, 'MPP_TRANSMIT:You must first call mpp_init.') if(to_pe.EQ.NULL_PE .AND. from_pe.EQ.NULL_PE) return block_comm=.true. if(PRESENT(block)) block_comm=block if(debug) then call SYSTEM_CLOCK(tick) write(stdout_unit,'(a, i18, a, i6, a, 2i6, 2i8)')&'T=', tick, ' PE=', pe, ' MPP_TRANSMIT begin:to_pe, from_pe, put_len, get_len=', to_pe, from_pe, put_len, get_len end if comm_tag=DEFAULT_TAG if(present(tag)) comm_tag=tag!do put first and then get if(to_pe.GE.0 .AND. to_pe.LT.npes) then!use non-blocking sends if(debug .and.(current_clock.NE.0)) call SYSTEM_CLOCK(start_tick)!z1l:truly non-blocking send.! if(request(to_pe).NE.MPI_REQUEST_NULL) then !only one message from pe-> to_pe in queue *PE waiting for to_pe ! call error else get_len so only do gets but you cannot have a pure get with MPI call a get means do a wait to ensure put on remote PE is complete error call increase mpp_nml request_multiply call MPP_TRANSMIT get_len end if return end subroutine MPP_TRANSMIT_ ! MPP_BROADCAST ! subroutine but that doesn t allow !broadcast to a subset of PEs This version and mpp_transmit will remain !backward compatible intent(inout) a
*f90 *************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************subroutine MPP_UPDATE_NEST_FINE_2D_(field, nest_domain, wbuffer, ebuffer, sbuffer, nbuffer, &flags, complete, position, extra_halo, name, tile_count) MPP_TYPE_, intent(in) ::field(:,:) type(nest_domain_type), intent(inout) ::nest_domain MPP_TYPE_, intent(inout) ::wbuffer(:,:) MPP_TYPE_, intent(inout) ::ebuffer(:,:) MPP_TYPE_, intent(inout) ::sbuffer(:,:) MPP_TYPE_, intent(inout) ::nbuffer(:,:) integer, intent(in), optional ::flags logical, intent(in), optional ::complete integer, intent(in), optional ::position integer, intent(in), optional ::extra_halo character(len= *), intent(in), optional ::name integer, intent(in), optional ::tile_count MPP_TYPE_ ::field3D(size(field, 1), size(field, 2), 1) MPP_TYPE_ ::wbuffer3D(size(wbuffer, 1), size(wbuffer, 2), 1) MPP_TYPE_ ::ebuffer3D(size(ebuffer, 1), size(ebuffer, 2), 1) MPP_TYPE_ ::sbuffer3D(size(sbuffer, 1), size(sbuffer, 2), 1) MPP_TYPE_ ::nbuffer3D(size(nbuffer, 1), size(nbuffer, 2), 1) pointer(ptr, field3D) pointer(ptr_w, wbuffer3D) pointer(ptr_e, ebuffer3D) pointer(ptr_s, sbuffer3D) pointer(ptr_n, nbuffer3D) ptr=LOC(field) ptr_w=LOC(wbuffer) ptr_e=LOC(ebuffer) ptr_s=LOC(sbuffer) ptr_n=LOC(nbuffer) call mpp_update_nest_fine(field3D, nest_domain, wbuffer3D, ebuffer3D, sbuffer3D, nbuffer3D, &flags, complete, position, extra_halo, name, tile_count) returnend subroutine MPP_UPDATE_NEST_FINE_2D_subroutine MPP_UPDATE_NEST_FINE_3D_(field, nest_domain, wbuffer, sbuffer, ebuffer, nbuffer, &flags, complete, position, extra_halo, name, tile_count) MPP_TYPE_, intent(in) ::field(:,:,:) type(nest_domain_type), intent(inout) ::nest_domain MPP_TYPE_, intent(inout) ::wbuffer(:,:,:) MPP_TYPE_, intent(inout) ::ebuffer(:,:,:) MPP_TYPE_, intent(inout) ::sbuffer(:,:,:) MPP_TYPE_, intent(inout) ::nbuffer(:,:,:) integer, intent(in), optional ::flags logical, intent(in), optional ::complete integer, intent(in), optional ::position integer, intent(in), optional ::extra_halo character(len= *), intent(in), optional ::name integer, intent(in), optional ::tile_count MPP_TYPE_ ::d_type type(nestSpec), pointer ::update=> dimension(MAX_DOMAIN_FIELDS)
real(r8), dimension(cast_m, cast_n) t
*f90 *************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If not
************************************************************************GNU Lesser General Public License **This file is part of the GFDL Flexible Modeling System(FMS). ! *! *FMS is free software without even the implied warranty of MERCHANTABILITY or *FITNESS FOR A PARTICULAR PURPOSE See the GNU General Public License *for more details **You should have received a copy of the GNU Lesser General Public *License along with FMS If see< http:! ***********************************************************************subroutine READ_RECORD_CORE_(unit, field, nwords, data, start, axsiz) integer, intent(in) ::unit type(fieldtype), intent(in) ::field integer, intent(in) ::nwords MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in) ::start(:), axsiz(:) integer(SHORT_KIND) ::i2vals(nwords)!rab used in conjunction with transfer intrinsic to determine size of a variable integer(KIND=1) ::one_byte(8) integer ::word_sz!#ifdef __sgi integer(INT_KIND) ::ivals(nwords) real(FLOAT_KIND) ::rvals(nwords)!#else! integer ::ivals(nwords)! real ::rvals(nwords)!#endif real(DOUBLE_KIND) ::r8vals(nwords) pointer(ptr1, i2vals) pointer(ptr2, ivals) pointer(ptr3, rvals) pointer(ptr4, r8vals) if(mpp_io_stack_size< nwords) call mpp_io_set_stack_size(nwords) call mpp_error(FATAL, 'MPP_READ currently requires use_netCDF option') end subroutine READ_RECORD_CORE_ subroutine READ_RECORD_(unit, field, nwords, data, time_level, domain, position, tile_count, start_in, axsiz_in)!routine that is finally called by all mpp_read routines to perform the read!a non-netCDF record contains:! field ID! a set of 4 coordinates(is:ie, js:je) giving the data subdomain! a timelevel and a timestamp(=NULLTIME if field is static)! 3D real data(stored as 1D)!if you are using direct access I/O, the RECL argument to OPEN must be large enough for the above!in a global direct access file, record position on PE is given by %record.!Treatment of timestamp:! We assume that static fields have been passed without a timestamp.! Here that is converted into a timestamp of NULLTIME.! For non-netCDF fields, field is treated no differently, but is written! with a timestamp of NULLTIME. There is no check in the code to prevent! the user from repeatedly writing a static field. integer, intent(in) ::unit, nwords type(fieldtype), intent(in) ::field MPP_TYPE_, intent(inout) ::data(nwords) integer, intent(in), optional ::time_level type(domain2D), intent(in), optional ::domain integer, intent(in), optional ::position, tile_count integer, intent(in), optional ::start_in(:), axsiz_in(:) integer, dimension(size(field%axes(:))) ::start, axsiz integer ::tlevel !, subdomain(4) integer ::i, error, is, ie, js, je, isg, ieg, jsg, jeg type(domain2d), pointer ::io_domain=> time_level
integer ndim
No description.