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 2462 for branches/DEV_r2460_v3_3beta_NOL/NEMOGCM/NEMO/OPA_SRC/LBC/mppini_2.h90 – NEMO

Ignore:
Timestamp:
2010-12-07T18:56:19+01:00 (13 years ago)
Author:
acc
Message:

DEV_r2460_v3_3beta_NOL. Changes to v3.3beta to improve assignment of ocean processes to ioserver processes when discarding land-only regions. See ticket #776

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/DEV_r2460_v3_3beta_NOL/NEMOGCM/NEMO/OPA_SRC/LBC/mppini_2.h90

    r2442 r2462  
    4141      USE in_out_manager  ! I/O Manager 
    4242      USE iom 
     43#if defined key_iomput 
     44      USE mod_event_client 
     45# endif 
    4346      !!  
    4447      INTEGER :: ji, jj, jn, jproc, jarea     ! dummy loop indices 
     
    288291            iin(icont+1) = ii 
    289292            ijn(icont+1) = ij 
     293            nregproc_out(icont+1) = jarea - 1 
    290294         ENDIF 
    291295      END DO 
     
    461465      IF (lwp) THEN 
    462466         CALL ctl_opn( inum, 'layout.dat', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE., narea ) 
    463          WRITE(inum,'(6i8)') jpnij,jpi,jpj,jpk,jpiglo,jpjglo 
    464          WRITE(inum,'(a)') 'NAREA nlci nlcj nldi nldj nlei nlej nimpp njmpp' 
     467         WRITE(inum,'(8i8)') jpnij,jpi,jpj,jpk,jpiglo,jpjglo,jpni,jpnj 
     468         WRITE(inum,'(a)') 'NAREA nlci nlcj nldi nldj nlei nlej nimpp njmpp nregproc_out' 
    465469 
    466470        DO  jproc = 1, jpnij 
    467          WRITE(inum,'(9i5)') jproc, nlcit(jproc), nlcjt(jproc), & 
     471         WRITE(inum,'(10i5)') jproc, nlcit(jproc), nlcjt(jproc), & 
    468472                                      nldit(jproc), nldjt(jproc), & 
    469473                                      nleit(jproc), nlejt(jproc), & 
    470                                       nimppt(jproc), njmppt(jproc) 
     474                                      nimppt(jproc), njmppt(jproc), nregproc_out(jproc) 
    471475        END DO 
    472476        CLOSE(inum)    
     477#ifdef key_iomput 
     478     ! Check nregproc_in matches nregproc_out and abort if it does not. 
     479     ! This should only occur on the first run of a new domain decomposition 
     480     ! when jpni*jpnj /= jpnij. If ioservers are not being used, Init_parallel 
     481     ! will not have been called and nregproc_in will not have been allocated. 
     482     ! In such a case the check is unnecessary so only check for a match if 
     483     ! nregproc_in has been allocated. 
     484       IF (ALLOCATED(nregproc_in)) THEN 
     485        DO  jn = 1, jpnij 
     486         IF ( nregproc_in(jn) /= nregproc_out(jn) ) THEN 
     487          WRITE(numout,*) ' nregproc_in and nregproc_out do not match.' 
     488          WRITE(numout,*) ' This is expected when starting a new domain docomposition.' 
     489          WRITE(numout,*) ' The layout.dat file has been updated and the model may be rerun.' 
     490          CALL ctl_stop( ' mpp_init: IO server domain colour assignment mismatch ') 
     491         END IF 
     492        END DO 
     493       END IF 
     494#endif 
    473495      END IF 
    474496 
Note: See TracChangeset for help on using the changeset viewer.