New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 3145 for branches/2011/dev_NEMO_MERGE_2011/NEMOGCM/NEMO/LIM_SRC_2/limmsh_2.F90 – NEMO

Ignore:
Timestamp:
2011-11-17T16:53:24+01:00 (13 years ago)
Author:
smasson
Message:

dev_NEMO_MERGE_2011: new dynamical allocation in LIM2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2011/dev_NEMO_MERGE_2011/NEMOGCM/NEMO/LIM_SRC_2/limmsh_2.F90

    r2715 r3145  
    2020   USE in_out_manager 
    2121   USE lib_mpp          ! MPP library 
     22#if defined key_lim2_vp 
     23   USE wrk_nemo_2       ! work arrays 
     24#endif 
    2225 
    2326   IMPLICIT NONE 
     
    4649      !! ** Refer.  : Deleersnijder et al. Ocean Modelling 100, 7-10  
    4750      !!---------------------------------------------------------------------  
    48       USE wrk_nemo, ONLY: wrk_in_use, wrk_not_released 
    49       USE wrk_nemo, ONLY: zd2d1 => wrk_2d_1, zd1d2 => wrk_2d_2 
    5051      INTEGER :: ji, jj      ! dummy loop indices 
    5152      REAL(wp) ::   zusden   ! local scalars 
     
    5455      REAL(wp) ::   zh1p  , zh2p      !   -      - 
    5556      REAL(wp) ::   zd2d1p, zd1d2p    !   -      - 
     57      REAL(wp), POINTER, DIMENSION(:,:) ::   zd2d1, zd1d2   ! 2D workspace 
    5658#endif 
    5759      !!--------------------------------------------------------------------- 
    5860 
    59       IF( wrk_in_use(2, 1,2) ) THEN 
    60          CALL ctl_stop('lim_msh_2 : requested workspace arrays unavailable')   ;   RETURN 
    61       ENDIF 
     61#if defined key_lim2_vp 
     62      CALL wrk_alloc( jpi, jpj, zd2d1, zd1d2 ) 
     63#endif 
    6264 
    6365      IF(lwp) THEN 
     
    281283      area(:,:) = e1t(:,:) * e2t(:,:) 
    282284      ! 
    283       IF( wrk_not_released(2, 1,2) )   CALL ctl_stop('lim_msh_2 : failed to release workspace arrays') 
     285#if defined key_lim2_vp 
     286      CALL wrk_dealloc( jpi, jpj, zd2d1, zd1d2 ) 
     287#endif 
    284288      ! 
    285289   END SUBROUTINE lim_msh_2 
Note: See TracChangeset for help on using the changeset viewer.