Ignore:
Timestamp:
2019-11-07T17:55:13+01:00 (11 months ago)
Author:
acc
Message:

Branch 2019/fix_sn_cfctl_ticket2328. See #2328. Replacement of ln_ctl and activation of full functionality with
sn_cfctl structure. These changes rename structure components l_mppout and l_mpptop as l_prtctl and l_prttrc
and introduce l_glochk to activate former ln_ctl code in stpctl.F90 to perform global location of min and max
checks. Also added is l_allon which can be used to activate all output (much like the former ln_ctl). If l_allon
is .false. then l_config decides whether or not the suboptions are used.

   sn_cfctl%l_glochk = .FALSE.    ! Range sanity checks are local (F) or global (T). Set T for debugging only
   sn_cfctl%l_allon  = .FALSE.    ! IF T activate all options. If F deactivate all unless l_config is T
   sn_cfctl%l_config = .TRUE.     ! IF .true. then control which reports are written with the remaining options

Note, these changes pass SETTE tests but all references to ln_ctl need to be removed from the sette scripts.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/fix_sn_cfctl_ticket2328/src/SAO/nemogcm.F90

    r11869 r11872  
    9191      INTEGER ::   ios, ilocal_comm   ! local integer 
    9292      ! 
    93       NAMELIST/namctl/ ln_ctl   , sn_cfctl, nn_print, nn_ictls, nn_ictle,   & 
     93      NAMELIST/namctl/ sn_cfctl,  nn_print, nn_ictls, nn_ictle,             & 
    9494         &             nn_isplt , nn_jsplt, nn_jctls, nn_jctle,             & 
    9595         &             ln_timing, ln_diacfl 
     
    142142      ! 
    143143      !                             !--------------------! 
    144       !                             ! Open listing units !  -> need ln_ctl from namctl to define lwp 
     144      !                             ! Open listing units !  -> need sn_cfctl from namctl to define lwp 
    145145      !                             !--------------------! 
    146146      ! 
     
    153153      ! 
    154154      ! finalize the definition of namctl variables 
    155       IF( sn_cfctl%l_config ) THEN 
     155      IF( sn_cfctl%l_allon ) THEN 
     156         ! Turn on all options. 
     157         CALL nemo_set_cfctl( sn_cfctl, .TRUE., .TRUE. ) 
     158         ! Ensure all processors are active 
     159         sn_cfctl%procmin = 0 ; sn_cfctl%procmax = 1000000 ; sn_cfctl%procincr = 1 
     160      ELSEIF( sn_cfctl%l_config ) THEN 
    156161         ! Activate finer control of report outputs 
    157162         ! optionally switch off output from selected areas (note this only 
     
    161166           &   CALL nemo_set_cfctl( sn_cfctl, .FALSE., .FALSE. ) 
    162167      ELSE 
    163          ! Use ln_ctl to turn on or off all options. 
    164          CALL nemo_set_cfctl( sn_cfctl, ln_ctl, .TRUE. ) 
    165       ENDIF 
    166       ! 
    167       lwp = (narea == 1) .OR. ln_ctl .OR. sn_cfctl%l_oceout    ! control of all listing output print 
     168         ! turn off all options. 
     169         CALL nemo_set_cfctl( sn_cfctl, .FALSE., .TRUE. ) 
     170      ENDIF 
     171      ! 
     172      lwp = (narea == 1) .OR. sn_cfctl%l_oceout    ! control of all listing output print 
    168173      ! 
    169174      IF(lwp) THEN                      ! open listing units 
     
    241246 
    242247 
    243       IF( ln_ctl .OR. sn_cfctl%l_mppout )   & 
     248      IF( sn_cfctl%l_prtctl )   & 
    244249         &                 CALL prt_ctl_init       ! Print control 
    245250 
     
    254259      !! ** Purpose :   control print setting 
    255260      !! 
    256       !! ** Method  : - print namctl information and check some consistencies 
     261      !! ** Method  : - print namctl and namcfg information and check some consistencies 
    257262      !!---------------------------------------------------------------------- 
    258263      ! 
     
    262267         WRITE(numout,*) '~~~~~~~~' 
    263268         WRITE(numout,*) '   Namelist namctl' 
    264          WRITE(numout,*) '      run control (for debugging)     ln_ctl     = ', ln_ctl 
     269         WRITE(numout,*) '                              sn_cfctl%l_glochk  = ', sn_cfctl%l_glochk 
     270         WRITE(numout,*) '                              sn_cfctl%l_allon   = ', sn_cfctl%l_allon 
    265271         WRITE(numout,*) '       finer control over o/p sn_cfctl%l_config  = ', sn_cfctl%l_config 
    266272         WRITE(numout,*) '                              sn_cfctl%l_runstat = ', sn_cfctl%l_runstat 
     
    268274         WRITE(numout,*) '                              sn_cfctl%l_oceout  = ', sn_cfctl%l_oceout 
    269275         WRITE(numout,*) '                              sn_cfctl%l_layout  = ', sn_cfctl%l_layout 
    270          WRITE(numout,*) '                              sn_cfctl%l_mppout  = ', sn_cfctl%l_mppout 
    271          WRITE(numout,*) '                              sn_cfctl%l_mpptop  = ', sn_cfctl%l_mpptop 
     276         WRITE(numout,*) '                              sn_cfctl%l_prtctl  = ', sn_cfctl%l_prtctl 
     277         WRITE(numout,*) '                              sn_cfctl%l_prttrc  = ', sn_cfctl%l_prttrc 
     278         WRITE(numout,*) '                              sn_cfctl%l_oasout  = ', sn_cfctl%l_oasout 
    272279         WRITE(numout,*) '                              sn_cfctl%procmin   = ', sn_cfctl%procmin   
    273280         WRITE(numout,*) '                              sn_cfctl%procmax   = ', sn_cfctl%procmax   
     
    307314      !                             ! Parameter control 
    308315      ! 
    309       IF( ln_ctl .OR. sn_cfctl%l_mppout ) THEN                         ! sub-domain area indices for the control prints 
     316      IF( sn_cfctl%l_prtctl .OR. sn_cfctl%l_prttrc ) THEN              ! sub-domain area indices for the control prints 
    310317         IF( lk_mpp .AND. jpnij > 1 ) THEN 
    311318            isplt = jpni   ;   jsplt = jpnj   ;   ijsplt = jpni*jpnj   ! the domain is forced to the real split domain 
     
    427434      sn_cfctl%l_oceout  = setto 
    428435      sn_cfctl%l_layout  = setto 
    429       sn_cfctl%l_mppout  = setto 
    430       sn_cfctl%l_mpptop  = setto 
     436      sn_cfctl%l_prtctl  = setto 
     437      sn_cfctl%l_prttrc  = setto 
    431438      sn_cfctl%l_oasout  = setto 
    432439   END SUBROUTINE nemo_set_cfctl 
Note: See TracChangeset for help on using the changeset viewer.