Back to home page

MITgcm

 
 

    


File indexing completed on 2020-07-29 05:10:37 UTC

view on githubraw file Latest commit b9dadda2 on 2020-07-28 16:49:33 UTC
924557e60a Chri*0001 #include "CPP_EEOPTIONS.h"
                0002 
4c563c2ee9 Chri*0003 CBOP
                0004 C     !ROUTINE: EEWRITE_EEENV
                0005 
                0006 C     !INTERFACE:
924557e60a Chri*0007       SUBROUTINE EEWRITE_EEENV
                0008 
4c563c2ee9 Chri*0009 C     !DESCRIPTION:
                0010 C     *==========================================================*
8ad19e1d95 Jean*0011 C     | SUBROUTINE EERWITE\_EEENV
                0012 C     | o Write execution environment summary
4c563c2ee9 Chri*0013 C     *==========================================================*
8ad19e1d95 Jean*0014 C     | Write a summary of the execution environment as
                0015 C     | configured for this run. The execution environment is
                0016 C     | the computational mode in which the model operatoes. It
                0017 C     | includes the computational grid but does not include any
b9dadda204 Mart*0018 C     | model specific numerical parameters.
4c563c2ee9 Chri*0019 C     *==========================================================*
                0020 
                0021 C     !USES:
f902f5892c Jean*0022       IMPLICIT NONE
4c563c2ee9 Chri*0023 C     == Global data ==
924557e60a Chri*0024 #include "SIZE.h"
                0025 #include "EEPARAMS.h"
                0026 #include "EESUPPORT.h"
                0027 
4c563c2ee9 Chri*0028 C     !LOCAL VARIABLES:
                0029 C     == Local variables ==
                0030 C     msgBuf :: Temp. for building text messages.
924557e60a Chri*0031       CHARACTER*(MAX_LEN_MBUF) msgBuf
b9dadda204 Mart*0032       CHARACTER*(8) fmtStr
                0033       INTEGER iTmp
4c563c2ee9 Chri*0034 CEOP
8ad19e1d95 Jean*0035 
b9dadda204 Mart*0036       iTmp = MAX(5,1 + INT(LOG10(DFLOAT(MAX(Nx,Ny)))))
                0037       WRITE(fmtStr,'(A,I1,A)') '(A,I',iTmp,',A)'
                0038 
8ad19e1d95 Jean*0039       WRITE(msgBuf,'(A)')
46dc4f419b Chri*0040      & '// ======================================================='
924557e60a Chri*0041       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0042      &  SQUEEZE_RIGHT , 1)
                0043 
8ad19e1d95 Jean*0044       WRITE(msgBuf,'(A)')
46dc4f419b Chri*0045      & '// Computational Grid Specification ( see files "SIZE.h" )'
924557e60a Chri*0046       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0047      &  SQUEEZE_RIGHT , 1)
                0048 
8ad19e1d95 Jean*0049       WRITE(msgBuf,'(A)')
46dc4f419b Chri*0050      & '//                                  ( and "eedata"       )'
924557e60a Chri*0051       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0052      &  SQUEEZE_RIGHT , 1)
                0053 
8ad19e1d95 Jean*0054       WRITE(msgBuf,'(A)')
46dc4f419b Chri*0055      & '// ======================================================='
924557e60a Chri*0056       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0057      &  SQUEEZE_RIGHT , 1)
                0058 
b9dadda204 Mart*0059       WRITE(msgBuf,fmtStr) '     nPx =',nPx,
46dc4f419b Chri*0060      & ' ; /* No. processes in X */'
924557e60a Chri*0061       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0062      &  SQUEEZE_RIGHT , 1)
                0063 
b9dadda204 Mart*0064       WRITE(msgBuf,fmtStr) '     nPy =',nPy,
46dc4f419b Chri*0065      & ' ; /* No. processes in Y */'
924557e60a Chri*0066       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0067      &  SQUEEZE_RIGHT , 1)
                0068 
b9dadda204 Mart*0069       WRITE(msgBuf,fmtStr) '     nSx =',nSx,
46dc4f419b Chri*0070      & ' ; /* No. tiles in X per process */'
924557e60a Chri*0071       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0072      &  SQUEEZE_RIGHT , 1)
                0073 
b9dadda204 Mart*0074       WRITE(msgBuf,fmtStr) '     nSy =',nSy,
46dc4f419b Chri*0075      & ' ; /* No. tiles in Y per process */'
924557e60a Chri*0076       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0077      &  SQUEEZE_RIGHT , 1)
                0078 
b9dadda204 Mart*0079       WRITE(msgBuf,fmtStr) '     sNx =',sNx,
46dc4f419b Chri*0080      & ' ; /* Tile size in X */'
924557e60a Chri*0081       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0082      &  SQUEEZE_RIGHT , 1)
                0083 
b9dadda204 Mart*0084       WRITE(msgBuf,fmtStr) '     sNy =',sNy,
46dc4f419b Chri*0085      & ' ; /* Tile size in Y */'
924557e60a Chri*0086       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0087      &  SQUEEZE_RIGHT , 1)
                0088 
b9dadda204 Mart*0089       WRITE(msgBuf,fmtStr) '     OLx =',OLx,
924557e60a Chri*0090      & ' ; /* Tile overlap distance in X */'
                0091       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0092      &  SQUEEZE_RIGHT , 1)
                0093 
b9dadda204 Mart*0094       WRITE(msgBuf,fmtStr) '     OLy =',OLy,
924557e60a Chri*0095      & ' ; /* Tile overlap distance in Y */'
                0096       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0097      &  SQUEEZE_RIGHT , 1)
                0098 
b9dadda204 Mart*0099       WRITE(msgBuf,fmtStr) '     nTx =',nTx,
46dc4f419b Chri*0100      & ' ; /* No. threads in X per process */'
924557e60a Chri*0101       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0102      &  SQUEEZE_RIGHT , 1)
                0103 
b9dadda204 Mart*0104       WRITE(msgBuf,fmtStr) '     nTy =',nTy,
46dc4f419b Chri*0105      & ' ; /* No. threads in Y per process */'
924557e60a Chri*0106       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0107      &  SQUEEZE_RIGHT , 1)
                0108 
b9dadda204 Mart*0109       WRITE(msgBuf,fmtStr) '      Nr =', Nr,
46dc4f419b Chri*0110      & ' ; /* No. levels in the vertical   */ '
924557e60a Chri*0111       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0112      &  SQUEEZE_RIGHT , 1)
                0113 
b9dadda204 Mart*0114       WRITE(msgBuf,fmtStr) '      Nx =', Nx,
924557e60a Chri*0115      & ' ; /* Total domain size in X ( = nPx*nSx*sNx ) */'
                0116       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0117      &  SQUEEZE_RIGHT , 1)
                0118 
b9dadda204 Mart*0119       WRITE(msgBuf,fmtStr) '      Ny =', Ny,
924557e60a Chri*0120      & ' ; /* Total domain size in Y ( = nPy*nSy*sNy ) */'
                0121       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0122      &  SQUEEZE_RIGHT , 1)
                0123 
b9dadda204 Mart*0124       WRITE(msgBuf,fmtStr) '  nTiles =', nSx*nSy,
924557e60a Chri*0125      & ' ; /* Total no. tiles per process ( = nSx*nSy ) */'
                0126       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0127      &  SQUEEZE_RIGHT , 1)
                0128 
b9dadda204 Mart*0129       WRITE(msgBuf,fmtStr) '  nProcs =', nPx*nPy,
924557e60a Chri*0130      & ' ; /* Total no. processes ( = nPx*nPy ) */'
                0131       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0132      &  SQUEEZE_RIGHT , 1)
                0133 
b9dadda204 Mart*0134       WRITE(msgBuf,fmtStr) 'nThreads =', nTx*nTy,
924557e60a Chri*0135      & ' ; /* Total no. threads per process ( = nTx*nTy ) */'
                0136       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0137      &  SQUEEZE_RIGHT , 1)
                0138 
b9dadda204 Mart*0139       WRITE(fmtStr,'(A,I1,A)') '(A,L',iTmp,',A)'
                0140       WRITE(msgBuf,fmtStr) 'usingMPI =', usingMPI,
924557e60a Chri*0141      & ' ; /* Flag used to control whether MPI is in use */'
                0142       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0143      &  SQUEEZE_RIGHT , 1)
                0144 
b9dadda204 Mart*0145       WRITE(fmtStr,'(A,I1,A)') '(A,A',iTmp,',A)'
                0146       WRITE(msgBuf,fmtStr) '          ', '     ' ,
924557e60a Chri*0147      & '   /*  note: To execute a program with MPI calls */'
                0148       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0149      &  SQUEEZE_RIGHT , 1)
                0150 
b9dadda204 Mart*0151       WRITE(msgBuf,fmtStr) '          ', '     ' ,
924557e60a Chri*0152      & '   /*  it must be launched appropriately e.g     */'
                0153       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0154      &  SQUEEZE_RIGHT , 1)
                0155 
b9dadda204 Mart*0156       WRITE(msgBuf,fmtStr) '          ', '     ' ,
924557e60a Chri*0157      & '   /*  "mpirun -np 64 ......"                    */'
                0158       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0159      &  SQUEEZE_RIGHT , 1)
                0160 
b9dadda204 Mart*0161       WRITE(fmtStr,'(A,I1,A)') '(A,L',iTmp-1,',A)'
                0162       WRITE(msgBuf,fmtStr) 'useCoupler=', useCoupler,
                0163      & ' ; /* Flag used to control communications with   */'
ed584e7d0c Jean*0164       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0165      &  SQUEEZE_RIGHT , 1)
b9dadda204 Mart*0166       WRITE(fmtStr,'(A,I1,A)') '(A,A',iTmp,',A)'
                0167       WRITE(msgBuf,fmtStr)  '           ', '     ',
a4a4da6891 Jean*0168      & '  /*  other model components, through a coupler */'
ed584e7d0c Jean*0169       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0170      &  SQUEEZE_RIGHT , 1)
                0171 
6591b3fcc3 Jean*0172       WRITE(msgBuf,'(A,L5,A)') 'useNest2W_parent =', useNest2W_parent,
                0173      & ' ;/* Control 2-W Nesting comm */'
                0174       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0175      &  SQUEEZE_RIGHT , 1)
                0176       WRITE(msgBuf,'(A,L5,A)') 'useNest2W_child  =', useNest2W_child,
                0177      & ' ;/* Control 2-W Nesting comm */'
                0178       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0179      &  SQUEEZE_RIGHT , 1)
                0180 
f902f5892c Jean*0181       WRITE(msgBuf,'(A,L5,A)') 'debugMode =', debugMode,
                0182      & ' ; /* print debug msg. (sequence of S/R calls)  */'
                0183       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0184      &                    SQUEEZE_RIGHT , 1)
                0185       WRITE(msgBuf,'(A,L5,A)')
a4a4da6891 Jean*0186      &  'printMapIncludesZeros=', printMapIncludesZeros,
                0187      &  ' ; /* print zeros in Std.Output maps */'
                0188       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0189      &                    SQUEEZE_RIGHT , 1)
                0190       WRITE(msgBuf,'(A,I5,A)') 'maxLengthPrt1D=', maxLengthPrt1D,
                0191      &           ' /* maxLength of 1D array printed to StdOut */'
                0192       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0193      &                    SQUEEZE_RIGHT , 1)
ed584e7d0c Jean*0194 
924557e60a Chri*0195       WRITE(msgBuf,'(A)') '                '
                0196       CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0197      &  SQUEEZE_RIGHT , 1)
                0198 
                0199       RETURN
                0200       END