MOM6
MOM_safe_alloc.F90 File Reference

Go to the source code of this file.

Data Types

interface  mom_safe_alloc::safe_alloc_ptr
 Allocate a pointer to a 1-d, 2-d or 3-d array. More...
 
interface  mom_safe_alloc::safe_alloc_alloc
 Allocate a 2-d or 3-d allocatable array. More...
 

Modules

module  mom_safe_alloc
 Convenience functions for safely allocating memory without accidentally reallocating pointer and causing memory leaks.
 

Functions/Subroutines

subroutine mom_safe_alloc::safe_alloc_ptr_1d (ptr, i1, i2)
 Allocate a pointer to a 1-d array. More...
 
subroutine mom_safe_alloc::safe_alloc_ptr_2d_2arg (ptr, ni, nj)
 Allocate a pointer to a 2-d array based on its dimension sizes. More...
 
subroutine mom_safe_alloc::safe_alloc_ptr_3d_3arg (ptr, ni, nj, nk)
 Allocate a pointer to a 3-d array based on its dimension sizes. More...
 
subroutine mom_safe_alloc::safe_alloc_ptr_2d (ptr, is, ie, js, je)
 Allocate a pointer to a 2-d array based on its index starting and ending values. More...
 
subroutine mom_safe_alloc::safe_alloc_ptr_3d (ptr, is, ie, js, je, nk)
 Allocate a pointer to a 3-d array based on its index starting and ending values. More...
 
subroutine mom_safe_alloc::safe_alloc_ptr_3d_6arg (ptr, is, ie, js, je, ks, ke)
 Allocate a pointer to a 3-d array based on its index starting and ending values. More...
 
subroutine mom_safe_alloc::safe_alloc_allocatable_2d (ptr, is, ie, js, je)
 Allocate a 2-d allocatable array based on its index starting and ending values. More...
 
subroutine mom_safe_alloc::safe_alloc_allocatable_3d (ptr, is, ie, js, je, nk)
 Allocate a 3-d allocatable array based on its index starting and ending values and k-index size. More...
 
subroutine mom_safe_alloc::safe_alloc_allocatable_3d_6arg (ptr, is, ie, js, je, ks, ke)
 Allocate a 3-d allocatable array based on its 6 index starting and ending values. More...