Skip to content

Commit

Permalink
Fix compile/whitespace, add files to modules
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryan Mulhall committed Jun 17, 2021
1 parent c47cad2 commit c963ff4
Show file tree
Hide file tree
Showing 21 changed files with 66 additions and 75 deletions.
2 changes: 1 addition & 1 deletion docs/Doxyfile.in
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ OPTIMIZE_OUTPUT_VHDL = NO
# Note that for custom extensions you also need to set FILE_PATTERNS otherwise
# the files are not read by doxygen.

EXTENSION_MAPPING = F90=FortranFree inc=FortranFree h=FortranFree
EXTENSION_MAPPING = F90=FortranFree inc=FortranFree

# If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments
# according to the Markdown format, which allows for more readable
Expand Down
4 changes: 1 addition & 3 deletions horiz_interp/horiz_interp_spherical.F90
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,6 @@ subroutine horiz_interp_spherical_new(Interp, lon_in,lat_in,lon_out,lat_out, &
real, intent(in), dimension(:,:) :: lat_in !< Longitude (radians) for source data grid
real, intent(in), dimension(:,:) :: lon_out !< Longitude (radians) for output data grid
real, intent(in), dimension(:,:) :: lat_out !< Latitude (radians) for output data grid
integer, intent(in), optional :: verbose !< flag for amount of print output
logical, intent(in), optional :: src_modulo !< indicates if the boundary condition
!! along zonal boundary is cyclic or not. Cyclic when true
integer, intent(in), optional :: num_nbrs !< Number of nearest neighbors for regridding
Expand Down Expand Up @@ -275,8 +274,7 @@ end subroutine horiz_interp_spherical_new
!> Subroutine for performing the horizontal interpolation between two grids.
!! horiz_interp_spherical_new must be called before calling this routine.
subroutine horiz_interp_spherical( Interp, data_in, data_out, verbose, mask_in, mask_out, missing_value)
type (horiz_interp_type), intent(in) :: Interp
type(horiz_interp_type), intent(inout) :: Interp !< A derived type variable containing indices
type(horiz_interp_type), intent(in) :: Interp !< A derived type variable containing indices
!! and weights for subsequent interpolations. Returned
!! by a previous call to horiz_interp_spherical_new
real, intent(in), dimension(:,:) :: data_in !< Input data on source grid
Expand Down
4 changes: 2 additions & 2 deletions mpp/include/mpp_comm.inc
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!> @file
!> @ingroup mpp
!> @brief Imports various routines used for communications and calculations
!> @ingroup mpp_mod
!> @brief Imports checksum, gather, and scatter routines used for communications and calculations
!! between PE's in @ref mpp
#if defined(use_libMPI)
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_data_mpi.inc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_data_mod
!> @brief Holds dummy constants and stack data for @ref mpp_mod and @ref mpp_domains_mod.
!! Accessible through @ref mpp_data_mod

Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_data_nocomm.inc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!> @file
!> @ingroup mpp
!> @ingroup mpp_data_mod
!> @brief Holds dummy constants and stack data for @ref mpp_mod and @ref mpp_domains_mod.
!! Accessible through @ref mpp_data_mod

Expand Down
45 changes: 23 additions & 22 deletions mpp/include/mpp_define_nest_domains.inc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_domains_mod
!> @brief Routines for use in @ref mpp_domains_mod for routines utilizing
!! domains with nested grids

Expand Down Expand Up @@ -55,34 +55,34 @@
!! test_fms/mpp/test_mpp_domains.F90.\n
!!\n
!! @code{.F90}
!! if( concurrent ) then
!! call mpp_broadcast_domain(domain_fine)
!! call mpp_broadcast_domain(domain_coarse)
!! endif
!! if( concurrent ) then
!! call mpp_broadcast_domain(domain_fine)
!! call mpp_broadcast_domain(domain_coarse)
!! endif
!!
!! call mpp_define_nest_domains(nest_domain,domain,num_nest,nest_level(1:num_nest), &
!! tile_fine(1:num_nest), tile_coarse(1:num_nest), &
!! call mpp_define_nest_domains(nest_domain,domain,num_nest,nest_level(1:num_nest), &
!! tile_fine(1:num_nest), tile_coarse(1:num_nest), &
!! istart_coarse(1:num_nest), icount_coarse(1:num_nest), &
!! jstart_coarse(1:num_nest), jcount_coarse(1:num_nest), &
!! npes_nest_tile, x_refine(1:num_nest), y_refine(1:num_nest), &
!! extra_halo=extra_halo, name="nest_domain")
!!
!! call mpp_get_C2F_index(nest_domain, isw_f, iew_f, jsw_f, jew_f, isw_c, iew_c, jsw_c, jew_c, WEST, level)
!! call mpp_get_C2F_index(nest_domain, ise_f, iee_f, jse_f, jee_f, ise_c, iee_c, jse_c, jee_c, EAST, level)
!! call mpp_get_C2F_index(nest_domain, iss_f, ies_f, jss_f, jes_f, iss_c, ies_c, jss_c, jes_c, SOUTH, level)
!! call mpp_get_C2F_index(nest_domain, isn_f, ien_f, jsn_f, jen_f, isn_c, ien_c, jsn_c, jen_c, NORTH, level)
!! call mpp_get_C2F_index(nest_domain, isw_f, iew_f, jsw_f, jew_f, isw_c, iew_c, jsw_c, jew_c, WEST, level)
!! call mpp_get_C2F_index(nest_domain, ise_f, iee_f, jse_f, jee_f, ise_c, iee_c, jse_c, jee_c, EAST, level)
!! call mpp_get_C2F_index(nest_domain, iss_f, ies_f, jss_f, jes_f, iss_c, ies_c, jss_c, jes_c, SOUTH, level)
!! call mpp_get_C2F_index(nest_domain, isn_f, ien_f, jsn_f, jen_f, isn_c, ien_c, jsn_c, jen_c, NORTH, level)
!!
!! allocate(wbuffer(isw_c:iew_c, jsw_c:jew_c,nz))
!! allocate(ebuffer(ise_c:iee_c, jse_c:jee_c,nz))
!! allocate(sbuffer(iss_c:ies_c, jss_c:jes_c,nz))
!! allocate(nbuffer(isn_c:ien_c, jsn_c:jen_c,nz))
!! call mpp_update_nest_fine(x, nest_domain, wbuffer, sbuffer, ebuffer, nbuffer)
!! allocate(wbuffer(isw_c:iew_c, jsw_c:jew_c,nz))
!! allocate(ebuffer(ise_c:iee_c, jse_c:jee_c,nz))
!! allocate(sbuffer(iss_c:ies_c, jss_c:jes_c,nz))
!! allocate(nbuffer(isn_c:ien_c, jsn_c:jen_c,nz))
!! call mpp_update_nest_fine(x, nest_domain, wbuffer, sbuffer, ebuffer, nbuffer)
!!
!! call mpp_get_F2C_index(nest_domain, is_c, ie_c, js_c, je_c, is_f, ie_f, js_f, je_f, nest_level=level)
!! allocate(buffer (is_f:ie_f, js_f:je_f,nz))
!! call mpp_update_nest_coarse(x, nest_domain, buffer)
!! call mpp_get_F2C_index(nest_domain, is_c, ie_c, js_c, je_c, is_f, ie_f, js_f, je_f, nest_level=level)
!! allocate(buffer (is_f:ie_f, js_f:je_f,nz))
!! call mpp_update_nest_coarse(x, nest_domain, buffer)
!
!! call mpp_define_nest_domains (nest_domain, domain, num_nest, nest_level, tile_fine, tile_coarse, &
!! call mpp_define_nest_domains (nest_domain, domain, num_nest, nest_level, tile_fine, tile_coarse, &
!! istart_coarse, icount_coarse, jstart_coarse, jcount_coarse, &
!! npes_nest_tile, x_refine, y_refine, extra_halo, name)
!! @endcode
Expand Down Expand Up @@ -1526,10 +1526,11 @@ function search_C2F_nest_overlap(nest_domain, nest_level, extra_halo, position)
!> Get the index of the data passed from coarse grid to fine grid.
!!
!! <br>Example usage:
!!
!! call mpp_get_C2F_index(nest_domain, is_fine, ie_fine, js_fine, je_fine,
!! @code{.F90}
!! call mpp_get_C2F_index(nest_domain, is_fine, ie_fine, js_fine, je_fine,
!! is_coarse, ie_coarse, js_coarse, je_coarse, dir,
!! nest_level, position)
!! @endcode
subroutine mpp_get_C2F_index(nest_domain, is_fine, ie_fine, js_fine, je_fine, &
is_coarse, ie_coarse, js_coarse, je_coarse, dir, nest_level, position)

Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_domains_comm.inc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_domains_mod
!> @brief Routines for domain communications via @ref domaincommunicator2d

function mpp_redistribute_init_comm(domain_in,l_addrs_in, domain_out,l_addrs_out, &
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_domains_define.inc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_domains_mod
!> @brief Various routines handling domains in @ref mpp_domains_mod

! <SUBROUTINE NAME="mpp_define_layout2D" INTERFACE="mpp_define_layout">
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_domains_misc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_domains_mod
!> @brief Initialization and finalization routines for @ref mpp_domains_mod as well
!! as other utility routines.

Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_domains_reduce.inc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_domains_mod
!> @brief Routines for calculating data from distributed arrays

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Expand Down
10 changes: 5 additions & 5 deletions mpp/include/mpp_domains_util.inc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_domains_mod
!> @brief Utility routines for getting and setting values in @ref mpp_domains_mod

! <SUBROUTINE NAME="mpp_domains_set_stack_size">
Expand Down Expand Up @@ -301,10 +301,10 @@
!> @brief Modifies the indices of the input domain to create the supergrid domain
!!
!> This is an example of how to use mpp_create_super_grid_domain
!!
!! call mpp_copy_domain(domain_in, domain_out)
!! call super_grid_domain(domain_out)
!!
!! @code{.F90}
!! call mpp_copy_domain(domain_in, domain_out)
!! call super_grid_domain(domain_out)
!! @endcode
!! domain_in is the original domain, domain_out is the domain with the supergrid indices.
subroutine mpp_create_super_grid_domain(domain)
type(domain2D), intent(inout) :: domain !< Input domain
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_io_connect.inc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!> @file
!> @ingroup mpp
!> @ingroup mpp_io_mod
!> @brief Handles opening and closing files in @ref mpp_io_mod

! <SUBROUTINE NAME="mpp_open">
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_io_misc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!> @file
!> @ingroup mpp
!> @ingroup mpp_io_mod
!> @brief Misc. routines including initialization and finalization of @ref mpp_io_mod

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_io_read.inc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!> @file
!> @ingroup mpp
!> @ingroup mpp_io_mod
!> @brief Parallel file read routines for structured grids for use in @ref mpp_io_mod

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_io_unstructured_read.inc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_io_mod
!> @brief Parallel file reads for unstructured grids, used in @ref mpp_io_mod
!----------
!ug support
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_io_unstructured_write.inc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_io_mod
!> @brief Parallel file writes for unstructured grids, used in @ref mpp_io_mod
!----------
!ug support
Expand Down
25 changes: 7 additions & 18 deletions mpp/include/mpp_io_util.inc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_io_mod
!> @brief Routines to retrieve data used in @ref mpp_io_mod

!#####################################################################
Expand All @@ -45,7 +45,9 @@
!> @brief Get some general information about a file.
!!
!> <br>Example usage:
!! call mpp_get_info( unit, ndim, nvar, natt, ntime )
!! @code{.F90}
!! call mpp_get_info( unit, ndim, nvar, natt, ntime )
!! @endcode
subroutine mpp_get_info( unit, ndim, nvar, natt, ntime )

integer, intent(in) :: unit
Expand Down Expand Up @@ -323,26 +325,13 @@

end function mpp_get_default_calendar

!#####################################################################
! <SUBROUTINE NAME="mpp_get_times">
! <OVERVIEW>
! Get file time data.
! </OVERVIEW>
! <DESCRIPTION>
! Get file time data.
! </DESCRIPTION>
! <TEMPLATE>
! call mpp_get_times( unit, time_values )
! </TEMPLATE>
! <IN NAME="unit" TYPE="integer"> </IN>
! <INOUT NAME="time_values" TYPE="real(r8_kind)" DIM="(:)"> </INOUT>
! </SUBROUTINE>

!> @brief Get file time data.
!!
!> Copy time information from file and convert to time_type
!! <br>Example usage:
!! call mpp_get_times( unit, time_values)
!! @code{.F90}
!! call mpp_get_times( unit, time_values)
!! @endcode
subroutine mpp_get_times( unit, time_values )
integer, intent(in) :: unit
real, intent(inout) :: time_values(:)
Expand Down
22 changes: 11 additions & 11 deletions mpp/include/mpp_io_write.inc
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
! MPP_WRITE_META !
! !
!> @file
!> @ingroup mpp
!> @ingroup mpp_io_mod
!> @brief This series of routines is used to describe the contents of the file
!! being written on <unit>.
!!
Expand Down Expand Up @@ -94,16 +94,16 @@
!! I/O). If the <datLINK> element is allocated, it is considered to be a
!! space axis, otherwise it is a time axis with an unlimited dimension.
!! Only one time axis is allowed per file.
!!
!! subroutine mpp_write_meta_field( unit, field, axes, name, units, longname
!! standard_name, min, max, missing, fill, scale, add, pack)
!! integer, intent(in) :: unit
!! type(fieldtype), intent(out) :: field
!! type(axistype), intent(in) :: axes(:)
!! character(len=*), intent(in) :: name, units, longname, standard_name
!! real, intent(in), optional :: min, max, missing, fill, scale, add
!! integer, intent(in), optional :: pack
!!
!! @code{.F90}
!! subroutine mpp_write_meta_field( unit, field, axes, name, units, longname
!! standard_name, min, max, missing, fill, scale, add, pack)
!! integer, intent(in) :: unit
!! type(fieldtype), intent(out) :: field
!! type(axistype), intent(in) :: axes(:)
!! character(len=*), intent(in) :: name, units, longname, standard_name
!! real, intent(in), optional :: min, max, missing, fill, scale, add
!! integer, intent(in), optional :: pack
!! @endcode
!! This form defines a field. Metadata corresponding to the type
!! above are written to the file on <unit>. A unique ID for subsequent
!! references to this field is returned in field%id. At least one axis
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_unstruct_domain.inc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
!***********************************************************************

!> @file
!> @ingroup mpp
!> @ingroup mpp_domains_mod
!> @brief Routines for defining and managing unstructured grids

!#####################################################################
Expand Down
2 changes: 1 addition & 1 deletion mpp/include/mpp_util.inc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!> @file
!> @ingroup mpp
!> @ingroup mpp_mod
!> @brief General utility functions for use in @ref mpp_utilities_mod

#if defined(use_libMPI)
Expand Down
3 changes: 3 additions & 0 deletions mpp/include/system_clock.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
!* You should have received a copy of the GNU Lesser General Public
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!> @file
!> @ingroup mpp_mod

#if defined(use_libMPI)
#define SYSTEM_CLOCK system_clock_mpi

Expand Down

0 comments on commit c963ff4

Please sign in to comment.