assign_allocatable_I8P_6D Subroutine

private subroutine assign_allocatable_I8P_6D(lhs, rhs, msg, verbose)

Assign CPU variable with memory checking (kind I8P, rank 6). Variable is returned not allocated if right hand side is not allocated.

 use penf
 integer(I8P), allocatable :: a(:,:,:,:,:,:), b(:,:,:,:,:,:)
 allocate(b(1:1,1:2,1:3,1:4,1:5,1:6))
 call assign_allocatable(a, b)
 print*, allocated(a)

Arguments

Type IntentOptional Attributes Name
integer(kind=I8P), intent(inout), allocatable :: lhs(:,:,:,:,:,:)

Left hand side of assignement.

integer(kind=I8P), intent(in), allocatable :: rhs(:,:,:,:,:,:)

Right hand side of assignement.

character(len=*), intent(in), optional :: msg

Message to be printed in verbose mode.

logical, intent(in), optional :: verbose

Flag to activate verbose mode.


Calls

proc~~assign_allocatable_i8p_6d~~CallsGraph proc~assign_allocatable_i8p_6d assign_allocatable_I8P_6D interface~allocate_variable allocate_variable proc~assign_allocatable_i8p_6d->interface~allocate_variable proc~alloc_var_i1p_1d alloc_var_I1P_1D interface~allocate_variable->proc~alloc_var_i1p_1d proc~alloc_var_i1p_2d alloc_var_I1P_2D interface~allocate_variable->proc~alloc_var_i1p_2d proc~alloc_var_i1p_3d alloc_var_I1P_3D interface~allocate_variable->proc~alloc_var_i1p_3d proc~alloc_var_i1p_4d alloc_var_I1P_4D interface~allocate_variable->proc~alloc_var_i1p_4d proc~alloc_var_i1p_5d alloc_var_I1P_5D interface~allocate_variable->proc~alloc_var_i1p_5d proc~alloc_var_i1p_6d alloc_var_I1P_6D interface~allocate_variable->proc~alloc_var_i1p_6d proc~alloc_var_i1p_7d alloc_var_I1P_7D interface~allocate_variable->proc~alloc_var_i1p_7d proc~alloc_var_i2p_1d alloc_var_I2P_1D interface~allocate_variable->proc~alloc_var_i2p_1d proc~alloc_var_i2p_2d alloc_var_I2P_2D interface~allocate_variable->proc~alloc_var_i2p_2d proc~alloc_var_i2p_3d alloc_var_I2P_3D interface~allocate_variable->proc~alloc_var_i2p_3d proc~alloc_var_i2p_4d alloc_var_I2P_4D interface~allocate_variable->proc~alloc_var_i2p_4d proc~alloc_var_i2p_5d alloc_var_I2P_5D interface~allocate_variable->proc~alloc_var_i2p_5d proc~alloc_var_i2p_6d alloc_var_I2P_6D interface~allocate_variable->proc~alloc_var_i2p_6d proc~alloc_var_i2p_7d alloc_var_I2P_7D interface~allocate_variable->proc~alloc_var_i2p_7d proc~alloc_var_i4p_1d alloc_var_I4P_1D interface~allocate_variable->proc~alloc_var_i4p_1d proc~alloc_var_i4p_2d alloc_var_I4P_2D interface~allocate_variable->proc~alloc_var_i4p_2d proc~alloc_var_i4p_3d alloc_var_I4P_3D interface~allocate_variable->proc~alloc_var_i4p_3d proc~alloc_var_i4p_4d alloc_var_I4P_4D interface~allocate_variable->proc~alloc_var_i4p_4d proc~alloc_var_i4p_5d alloc_var_I4P_5D interface~allocate_variable->proc~alloc_var_i4p_5d proc~alloc_var_i4p_6d alloc_var_I4P_6D interface~allocate_variable->proc~alloc_var_i4p_6d proc~alloc_var_i4p_7d alloc_var_I4P_7D interface~allocate_variable->proc~alloc_var_i4p_7d proc~alloc_var_i8p_1d alloc_var_I8P_1D interface~allocate_variable->proc~alloc_var_i8p_1d proc~alloc_var_i8p_2d alloc_var_I8P_2D interface~allocate_variable->proc~alloc_var_i8p_2d proc~alloc_var_i8p_3d alloc_var_I8P_3D interface~allocate_variable->proc~alloc_var_i8p_3d proc~alloc_var_i8p_4d alloc_var_I8P_4D interface~allocate_variable->proc~alloc_var_i8p_4d proc~alloc_var_i8p_5d alloc_var_I8P_5D interface~allocate_variable->proc~alloc_var_i8p_5d proc~alloc_var_i8p_6d alloc_var_I8P_6D interface~allocate_variable->proc~alloc_var_i8p_6d proc~alloc_var_i8p_7d alloc_var_I8P_7D interface~allocate_variable->proc~alloc_var_i8p_7d proc~alloc_var_r4p_1d alloc_var_R4P_1D interface~allocate_variable->proc~alloc_var_r4p_1d proc~alloc_var_r4p_2d alloc_var_R4P_2D interface~allocate_variable->proc~alloc_var_r4p_2d proc~alloc_var_r4p_3d alloc_var_R4P_3D interface~allocate_variable->proc~alloc_var_r4p_3d proc~alloc_var_r4p_4d alloc_var_R4P_4D interface~allocate_variable->proc~alloc_var_r4p_4d proc~alloc_var_r4p_5d alloc_var_R4P_5D interface~allocate_variable->proc~alloc_var_r4p_5d proc~alloc_var_r4p_6d alloc_var_R4P_6D interface~allocate_variable->proc~alloc_var_r4p_6d proc~alloc_var_r4p_7d alloc_var_R4P_7D interface~allocate_variable->proc~alloc_var_r4p_7d proc~alloc_var_r8p_1d alloc_var_R8P_1D interface~allocate_variable->proc~alloc_var_r8p_1d proc~alloc_var_r8p_2d alloc_var_R8P_2D interface~allocate_variable->proc~alloc_var_r8p_2d proc~alloc_var_r8p_3d alloc_var_R8P_3D interface~allocate_variable->proc~alloc_var_r8p_3d proc~alloc_var_r8p_4d alloc_var_R8P_4D interface~allocate_variable->proc~alloc_var_r8p_4d proc~alloc_var_r8p_5d alloc_var_R8P_5D interface~allocate_variable->proc~alloc_var_r8p_5d proc~alloc_var_r8p_6d alloc_var_R8P_6D interface~allocate_variable->proc~alloc_var_r8p_6d proc~alloc_var_r8p_7d alloc_var_R8P_7D interface~allocate_variable->proc~alloc_var_r8p_7d interface~str str proc~alloc_var_i1p_1d->interface~str proc~get_memory_info get_memory_info proc~alloc_var_i1p_1d->proc~get_memory_info proc~alloc_var_i1p_2d->interface~str proc~alloc_var_i1p_2d->proc~get_memory_info proc~alloc_var_i1p_3d->interface~str proc~alloc_var_i1p_3d->proc~get_memory_info proc~alloc_var_i1p_4d->interface~str proc~alloc_var_i1p_4d->proc~get_memory_info proc~alloc_var_i1p_5d->interface~str proc~alloc_var_i1p_5d->proc~get_memory_info proc~alloc_var_i1p_6d->interface~str proc~alloc_var_i1p_6d->proc~get_memory_info proc~alloc_var_i1p_7d->interface~str proc~alloc_var_i1p_7d->proc~get_memory_info proc~alloc_var_i2p_1d->interface~str proc~alloc_var_i2p_1d->proc~get_memory_info proc~alloc_var_i2p_2d->interface~str proc~alloc_var_i2p_2d->proc~get_memory_info proc~alloc_var_i2p_3d->interface~str proc~alloc_var_i2p_3d->proc~get_memory_info proc~alloc_var_i2p_4d->interface~str proc~alloc_var_i2p_4d->proc~get_memory_info proc~alloc_var_i2p_5d->interface~str proc~alloc_var_i2p_5d->proc~get_memory_info proc~alloc_var_i2p_6d->interface~str proc~alloc_var_i2p_6d->proc~get_memory_info proc~alloc_var_i2p_7d->interface~str proc~alloc_var_i2p_7d->proc~get_memory_info proc~alloc_var_i4p_1d->interface~str proc~alloc_var_i4p_1d->proc~get_memory_info proc~alloc_var_i4p_2d->interface~str proc~alloc_var_i4p_2d->proc~get_memory_info proc~alloc_var_i4p_3d->interface~str proc~alloc_var_i4p_3d->proc~get_memory_info proc~alloc_var_i4p_4d->interface~str proc~alloc_var_i4p_4d->proc~get_memory_info proc~alloc_var_i4p_5d->interface~str proc~alloc_var_i4p_5d->proc~get_memory_info proc~alloc_var_i4p_6d->interface~str proc~alloc_var_i4p_6d->proc~get_memory_info proc~alloc_var_i4p_7d->interface~str proc~alloc_var_i4p_7d->proc~get_memory_info proc~alloc_var_i8p_1d->interface~str proc~alloc_var_i8p_1d->proc~get_memory_info proc~alloc_var_i8p_2d->interface~str proc~alloc_var_i8p_2d->proc~get_memory_info proc~alloc_var_i8p_3d->interface~str proc~alloc_var_i8p_3d->proc~get_memory_info proc~alloc_var_i8p_4d->interface~str proc~alloc_var_i8p_4d->proc~get_memory_info proc~alloc_var_i8p_5d->interface~str proc~alloc_var_i8p_5d->proc~get_memory_info proc~alloc_var_i8p_6d->interface~str proc~alloc_var_i8p_6d->proc~get_memory_info proc~alloc_var_i8p_7d->interface~str proc~alloc_var_i8p_7d->proc~get_memory_info proc~alloc_var_r4p_1d->interface~str proc~alloc_var_r4p_1d->proc~get_memory_info proc~alloc_var_r4p_2d->interface~str proc~alloc_var_r4p_2d->proc~get_memory_info proc~alloc_var_r4p_3d->interface~str proc~alloc_var_r4p_3d->proc~get_memory_info proc~alloc_var_r4p_4d->interface~str proc~alloc_var_r4p_4d->proc~get_memory_info proc~alloc_var_r4p_5d->interface~str proc~alloc_var_r4p_5d->proc~get_memory_info proc~alloc_var_r4p_6d->interface~str proc~alloc_var_r4p_6d->proc~get_memory_info proc~alloc_var_r4p_7d->interface~str proc~alloc_var_r4p_7d->proc~get_memory_info proc~alloc_var_r8p_1d->interface~str proc~alloc_var_r8p_1d->proc~get_memory_info proc~alloc_var_r8p_2d->interface~str proc~alloc_var_r8p_2d->proc~get_memory_info proc~alloc_var_r8p_3d->interface~str proc~alloc_var_r8p_3d->proc~get_memory_info proc~alloc_var_r8p_4d->interface~str proc~alloc_var_r8p_4d->proc~get_memory_info proc~alloc_var_r8p_5d->interface~str proc~alloc_var_r8p_5d->proc~get_memory_info proc~alloc_var_r8p_6d->interface~str proc~alloc_var_r8p_6d->proc~get_memory_info proc~alloc_var_r8p_7d->interface~str proc~alloc_var_r8p_7d->proc~get_memory_info proc~str_a_i1p str_a_I1P interface~str->proc~str_a_i1p proc~str_a_i2p str_a_I2P interface~str->proc~str_a_i2p proc~str_a_i4p str_a_I4P interface~str->proc~str_a_i4p proc~str_a_i8p str_a_I8P interface~str->proc~str_a_i8p proc~str_a_r4p str_a_R4P interface~str->proc~str_a_r4p proc~str_a_r8p str_a_R8P interface~str->proc~str_a_r8p proc~str_bol str_bol interface~str->proc~str_bol proc~str_i1p str_I1P interface~str->proc~str_i1p proc~str_i2p str_I2P interface~str->proc~str_i2p proc~str_i4p str_I4P interface~str->proc~str_i4p proc~str_i8p str_I8P interface~str->proc~str_i8p proc~str_r4p str_R4P interface~str->proc~str_r4p proc~str_r8p str_R8P interface~str->proc~str_r8p proc~strf_i1p strf_I1P interface~str->proc~strf_i1p proc~strf_i2p strf_I2P interface~str->proc~strf_i2p proc~strf_i4p strf_I4P interface~str->proc~strf_i4p proc~strf_i8p strf_I8P interface~str->proc~strf_i8p proc~strf_r4p strf_R4P interface~str->proc~strf_r4p proc~strf_r8p strf_R8P interface~str->proc~strf_r8p interface~cton cton proc~get_memory_info->interface~cton proc~ctoi_i1p ctoi_I1P interface~cton->proc~ctoi_i1p proc~ctoi_i2p ctoi_I2P interface~cton->proc~ctoi_i2p proc~ctoi_i4p ctoi_I4P interface~cton->proc~ctoi_i4p proc~ctoi_i8p ctoi_I8P interface~cton->proc~ctoi_i8p proc~ctor_r4p ctor_R4P interface~cton->proc~ctor_r4p proc~ctor_r8p ctor_R8P interface~cton->proc~ctor_r8p proc~str_a_i1p->proc~str_i1p proc~str_a_i2p->proc~str_i2p proc~str_a_i4p->proc~str_i4p proc~str_a_i8p->proc~str_i8p proc~str_a_r4p->proc~str_r4p proc~str_a_r8p->proc~str_r8p proc~compact_real_string compact_real_string proc~str_r4p->proc~compact_real_string proc~str_r8p->proc~compact_real_string

Called by

proc~~assign_allocatable_i8p_6d~~CalledByGraph proc~assign_allocatable_i8p_6d assign_allocatable_I8P_6D interface~assign_allocatable assign_allocatable interface~assign_allocatable->proc~assign_allocatable_i8p_6d program~volatile_doctest volatile_doctest program~volatile_doctest->interface~assign_allocatable program~volatile_doctest~100 volatile_doctest program~volatile_doctest~100->interface~assign_allocatable program~volatile_doctest~101 volatile_doctest program~volatile_doctest~101->interface~assign_allocatable program~volatile_doctest~102 volatile_doctest program~volatile_doctest~102->interface~assign_allocatable program~volatile_doctest~108 volatile_doctest program~volatile_doctest~108->interface~assign_allocatable program~volatile_doctest~110 volatile_doctest program~volatile_doctest~110->interface~assign_allocatable program~volatile_doctest~114 volatile_doctest program~volatile_doctest~114->interface~assign_allocatable program~volatile_doctest~117 volatile_doctest program~volatile_doctest~117->interface~assign_allocatable program~volatile_doctest~12 volatile_doctest program~volatile_doctest~12->interface~assign_allocatable program~volatile_doctest~120 volatile_doctest program~volatile_doctest~120->interface~assign_allocatable program~volatile_doctest~123 volatile_doctest program~volatile_doctest~123->interface~assign_allocatable program~volatile_doctest~129 volatile_doctest program~volatile_doctest~129->interface~assign_allocatable program~volatile_doctest~131 volatile_doctest program~volatile_doctest~131->interface~assign_allocatable program~volatile_doctest~134 volatile_doctest program~volatile_doctest~134->interface~assign_allocatable program~volatile_doctest~142 volatile_doctest program~volatile_doctest~142->interface~assign_allocatable program~volatile_doctest~144 volatile_doctest program~volatile_doctest~144->interface~assign_allocatable program~volatile_doctest~145 volatile_doctest program~volatile_doctest~145->interface~assign_allocatable program~volatile_doctest~146 volatile_doctest program~volatile_doctest~146->interface~assign_allocatable program~volatile_doctest~149 volatile_doctest program~volatile_doctest~149->interface~assign_allocatable program~volatile_doctest~153 volatile_doctest program~volatile_doctest~153->interface~assign_allocatable program~volatile_doctest~160 volatile_doctest program~volatile_doctest~160->interface~assign_allocatable program~volatile_doctest~166 volatile_doctest program~volatile_doctest~166->interface~assign_allocatable program~volatile_doctest~168 volatile_doctest program~volatile_doctest~168->interface~assign_allocatable program~volatile_doctest~169 volatile_doctest program~volatile_doctest~169->interface~assign_allocatable program~volatile_doctest~182 volatile_doctest program~volatile_doctest~182->interface~assign_allocatable program~volatile_doctest~189 volatile_doctest program~volatile_doctest~189->interface~assign_allocatable program~volatile_doctest~19 volatile_doctest program~volatile_doctest~19->interface~assign_allocatable program~volatile_doctest~192 volatile_doctest program~volatile_doctest~192->interface~assign_allocatable program~volatile_doctest~193 volatile_doctest program~volatile_doctest~193->interface~assign_allocatable program~volatile_doctest~199 volatile_doctest program~volatile_doctest~199->interface~assign_allocatable program~volatile_doctest~22 volatile_doctest program~volatile_doctest~22->interface~assign_allocatable program~volatile_doctest~23 volatile_doctest program~volatile_doctest~23->interface~assign_allocatable program~volatile_doctest~24 volatile_doctest program~volatile_doctest~24->interface~assign_allocatable program~volatile_doctest~28 volatile_doctest program~volatile_doctest~28->interface~assign_allocatable program~volatile_doctest~35 volatile_doctest program~volatile_doctest~35->interface~assign_allocatable program~volatile_doctest~37 volatile_doctest program~volatile_doctest~37->interface~assign_allocatable program~volatile_doctest~4 volatile_doctest program~volatile_doctest~4->interface~assign_allocatable program~volatile_doctest~44 volatile_doctest program~volatile_doctest~44->interface~assign_allocatable program~volatile_doctest~46 volatile_doctest program~volatile_doctest~46->interface~assign_allocatable program~volatile_doctest~52 volatile_doctest program~volatile_doctest~52->interface~assign_allocatable program~volatile_doctest~53 volatile_doctest program~volatile_doctest~53->interface~assign_allocatable program~volatile_doctest~56 volatile_doctest program~volatile_doctest~56->interface~assign_allocatable program~volatile_doctest~66 volatile_doctest program~volatile_doctest~66->interface~assign_allocatable program~volatile_doctest~69 volatile_doctest program~volatile_doctest~69->interface~assign_allocatable program~volatile_doctest~74 volatile_doctest program~volatile_doctest~74->interface~assign_allocatable program~volatile_doctest~78 volatile_doctest program~volatile_doctest~78->interface~assign_allocatable program~volatile_doctest~79 volatile_doctest program~volatile_doctest~79->interface~assign_allocatable program~volatile_doctest~83 volatile_doctest program~volatile_doctest~83->interface~assign_allocatable program~volatile_doctest~9 volatile_doctest program~volatile_doctest~9->interface~assign_allocatable

Source Code

   subroutine assign_allocatable_I8P_6D(lhs, rhs, msg, verbose)
   !< Assign CPU variable with memory checking (kind I8P, rank 6).
   !< Variable is returned not allocated if right hand side is not allocated.
   !<
   !<```fortran
   !< use penf
   !< integer(I8P), allocatable :: a(:,:,:,:,:,:), b(:,:,:,:,:,:)
   !< allocate(b(1:1,1:2,1:3,1:4,1:5,1:6))
   !< call assign_allocatable(a, b)
   !< print*, allocated(a)
   !<```
   !=> T <<<
   integer(I8P), allocatable, intent(inout)        :: lhs(:,:,:,:,:,:) !< Left hand side of assignement.
   integer(I8P), allocatable, intent(in)           :: rhs(:,:,:,:,:,:) !< Right hand side of assignement.
   character(*),              intent(in), optional :: msg              !< Message to be printed in verbose mode.
   logical,                   intent(in), optional :: verbose          !< Flag to activate verbose mode.

   if (allocated(lhs)) deallocate(lhs)
   if (allocated(rhs)) then
      if (size(rhs, dim=1)*size(rhs, dim=2)*size(rhs, dim=3)*size(rhs, dim=4)*size(rhs, dim=5)*size(rhs, dim=6)>0) then
         call allocate_variable(var=lhs,                                                  &
                                ulb=reshape([lbound(rhs,dim=1),ubound(rhs,dim=1),         &
                                             lbound(rhs,dim=2),ubound(rhs,dim=2),         &
                                             lbound(rhs,dim=3),ubound(rhs,dim=3),         &
                                             lbound(rhs,dim=4),ubound(rhs,dim=4),         &
                                             lbound(rhs,dim=5),ubound(rhs,dim=5),         &
                                             lbound(rhs,dim=6),ubound(rhs,dim=6)],[2,6]), &
                                msg=msg, verbose=verbose)
         lhs = rhs
      endif
   endif
   endsubroutine assign_allocatable_I8P_6D