Internal IO routines for the multi-grid model.
More...
|
| subroutine | wmiobs (IMOD) |
| | Stage internal boundary data in the data structure BPSTGE. More...
|
| |
| subroutine | wmiobg (IMOD, DONE) |
| | Gather internal boundary data for a given model. More...
|
| |
| subroutine | wmiobf (IMOD) |
| | Finalize staging of internal boundary data in the data structure BPSTGE (MPI only). More...
|
| |
| subroutine | wmiohs (IMOD) |
| | Stage internal high-to-low data in the data structure HGSTGE. More...
|
| |
| subroutine | wmiohg (IMOD, DONE) |
| | Gather internal high-to-low data for a given model. More...
|
| |
| subroutine | wmiohf (IMOD) |
| | Finalize staging of internal high-to-low data in the data structure HGSTGE (MPI only). More...
|
| |
| subroutine | wmioes (IMOD) |
| | Stage internal same-rank data in the data structure EQSTGE. More...
|
| |
| subroutine | wmioeg (IMOD, DONE) |
| | Gather internal same-rank data for a given model. More...
|
| |
| subroutine | wmioef (IMOD) |
| | Finalize staging of internal same-rank data in the data structure EQSTGE (MPI only). More...
|
| |
Internal IO routines for the multi-grid model.
- Author
- H. L. Tolman
- Date
- 28-Sep-2016
◆ wmiobf()
| subroutine wminiomd::wmiobf |
( |
integer, intent(in) |
IMOD | ) |
|
Finalize staging of internal boundary data in the data structure BPSTGE (MPI only).
Post appropriate 'wait' functions to assure that the communication has finished.
- Parameters
-
| [in] | IMOD | Model number of grid from which data has been staged. |
- Author
- H. L. Tolman
- Date
- 29-May-2006
Definition at line 1212 of file wminiomd.F90.
1295 INTEGER,
INTENT(IN) :: IMOD
1303 INTEGER,
POINTER :: NRQ, IRQ(:)
1304 INTEGER,
ALLOCATABLE :: STATUS(:,:)
1307 INTEGER,
SAVE :: IENT = 0
1311 CALL strace (ient,
'WMIOBF')
1318 WRITE (
mdst,9000) imod
1327 nrq =>
bpstge(j,imod)%NRQBPS
1333 IF ( nrq .EQ. 0 ) cycle
1334 irq =>
bpstge(j,imod)%IRQBPS
1340 ALLOCATE (
status(mpi_status_size,nrq) )
1341 CALL mpi_waitall ( nrq, irq,
status, ierr_mpi )
1349 DEALLOCATE (
bpstge(j,imod)%IRQBPS , &
1364 9000
FORMAT (
' TEST WMIOBF : FINALIZE STAGING DATA FROM GRID ',i3)
1365 9010
FORMAT (
' TEST WMIOBF : FINISHED WITH TARGET ',i3)
References wmmdatmd::bpstge, include(), wmmdatmd::mdst, wmmdatmd::nrgrd, and w3servmd::strace().
Referenced by wminitmd::wminit(), wminitmd::wminitnml(), and wmwavemd::wmwave().
◆ wmiobg()
| subroutine wminiomd::wmiobg |
( |
integer, intent(in) |
IMOD, |
|
|
logical, intent(out), optional |
DONE |
|
) |
| |
Gather internal boundary data for a given model.
For the shared memory version, data are gathered from the data structure BPSTGE. For the distributed memory version, the gathering of the data are finished first.
Gathering of data is triggered by the time stamp of the data that is presently in the storage arrays.
This routine preempts the data flow normally executed by W3IOBC and W3UBPT, and hence bypasses both routines in W3WAVE.
- Parameters
-
| [in] | IMOD | Model number of grid from which data is to be gathered. |
| [out] | DONE | Flag for completion of operation (opt). |
- Author
- H. L. Tolman
- Date
- 29-May-2006
Definition at line 497 of file wminiomd.F90.
608 INTEGER,
INTENT(IN) :: IMOD
609 LOGICAL,
INTENT(OUT),
OPTIONAL :: DONE
614 INTEGER :: J, I, IOFF, TTEST(2), ITEST
616 INTEGER :: IERR_MPI, IT0, ITAG, IFROM, &
623 INTEGER,
SAVE :: IENT = 0
625 INTEGER,
POINTER :: VTIME(:)
627 INTEGER,
POINTER :: NRQ, IRQ(:)
628 INTEGER,
ALLOCATABLE :: STATUS(:,:)
630 REAL :: DTTST, DT1, DT2, W1, W2
631 REAL,
POINTER :: SBPI(:,:)
633 REAL,
ALLOCATABLE :: TSTORE(:,:)
641 CALL strace (ient,
'WMIOBG')
650 WRITE (
mdst,9000) imod
654 IF (
PRESENT(done) ) done = .false.
659 IF (
PRESENT(done) ) done = .true.
666 IF ( sum(
nbi2g(imod,:)) .EQ. 0 )
THEN
667 IF (
PRESENT(done) ) done = .true.
678 IF (
tbpin(1) .NE. -1 )
THEN
680 IF (
PRESENT(done) ) done = .true.
702 IF (
nbi2g(imod,j) .EQ. 0 ) cycle
703 vtime =>
bpstge(imod,j)%VTIME
707 IF ( vtime(1) .EQ. -1 )
THEN
715 IF ( dttst.LE.0. .AND.
tbpin(1).NE.-1 )
RETURN
733 IF (
nbista(imod) .EQ. 0 )
THEN
737 nrq =>
mdatas(imod)%NRQBPG
739 ALLOCATE (
mdatas(imod)%IRQBPG(nrq) )
740 irq =>
mdatas(imod)%IRQBPG
747 IF (
nbi2g(imod,j) .EQ. 0 ) cycle
753 IF (
bpstge(imod,j)%INIT )
THEN
754 IF (
respec(imod,j) )
THEN
755 DEALLOCATE (
bpstge(imod,j)%SBPI )
756 bpstge(imod,j)%INIT = .false.
759 WRITE (
mdst,9012) j,
'RESET'
763 IF (
SIZE(
bpstge(imod,j)%SBPI(:,1)) .NE. &
764 sgrds(j)%NSPEC .OR. &
765 SIZE(
bpstge(imod,j)%SBPI(1,:)) .NE. &
772 WRITE (
mdst,9012) j,
'TESTED'
780 IF ( .NOT.
bpstge(imod,j)%INIT )
THEN
784 bpstge(imod,j)%INIT = .true.
787 WRITE (
mdst,9012) j,
'INITIALIZED'
796 vtime =>
bpstge(imod,j)%VTIME
797 IF ( vtime(1) .EQ. -1 )
THEN
804 WRITE (
mdst,9013) vtime, dttst
810 IF ( dttst .LE. 0. )
THEN
820 ifrom =
mdatas(j)%CROOT - 1
822 CALL mpi_irecv (
bpstge(imod,j)%VTIME, 2, &
823 mpi_integer, ifrom, itag, &
828 WRITE (
mdst,9015) nrq, ifrom+1, itag-
mtag0, &
838 ioff = sum(
nbi2g(imod,1:j-1))
844 + sum(
nbi2g(imod,1:j-1))
848 sbpi =>
bpstge(imod,j)%SBPI
854 DO i=1,
nbi2g(imod,j)
855 isea =
nbi2s(ioff+i,2)
859 CALL mpi_irecv ( sbpi(1,i),
nspec, &
860 mpi_real, isproc-1, &
865 WRITE (
mdst,9016) nrq, jsea, isproc, &
866 itag-
mtag0, irq(nrq), ierr_mpi
889 WRITE (
mdst,9018) nrq
896 IF (
nbi .GT. 0 )
THEN
917 IF (
nbista(imod) .EQ. 1 )
THEN
921 nrq =>
mdatas(imod)%NRQBPG
922 irq =>
mdatas(imod)%IRQBPG
923 ALLOCATE (
status(mpi_status_size,nrq) )
929 IF (
PRESENT(done) )
THEN
933 CALL mpi_testall ( nrq, irq, flagok,
status, &
940 CALL mpi_test ( irq(i), flag,
status(1,1), &
942 flagok = flagok .AND. flag
943 IF ( flag ) icount = icount + 1
945 WRITE (
mdst,9019) 100. * real(icount) / real(nrq)
953 CALL mpi_waitall ( nrq, irq,
status, ierr_mpi )
969 DEALLOCATE (
mdatas(imod)%IRQBPG )
990 IF (
respec(imod,j) .AND.
nbi2g(imod,j).NE.0 )
THEN
1000 tstore =
bpstge(imod,j)%SBPI
1001 DEALLOCATE (
bpstge(imod,j)%SBPI )
1006 sbpi =>
bpstge(imod,j)%SBPI
1014 DEALLOCATE ( tstore )
1047 IF (
nbi2g(imod,j) .EQ. 0 ) cycle
1048 vtime =>
bpstge(imod,j)%VTIME
1049 IF ( ttest(1) .EQ. -1 )
THEN
1052 dttst =
dsec21(vtime,ttest)
1053 IF ( dttst .GT. 0. ) ttest = vtime
1058 WRITE (
mdst,9021) ttest
1063 IF (
tbpin(1) .EQ. -1 )
THEN
1065 IF ( dttst .NE. 0. )
THEN
1079 IF (
nbi2g(imod,j) .EQ. 0 ) cycle
1080 vtime =>
bpstge(imod,j)%VTIME
1081 sbpi =>
bpstge(imod,j)%SBPI
1083 IF ( j .EQ. 1 )
THEN
1086 ioff = sum(
nbi2g(imod,1:j-1))
1089 IF (
tbpin(1) .EQ. -1 )
THEN
1099 WRITE (
mdst,9022)
nbi2g(imod,j), j, ioff+1, w1, w2
1104 w2 * sbpi(:,1:
nbi2g(imod,j))
1134 IF (
PRESENT(done) ) done = .true.
1141 1001
FORMAT (/
' *** ERROR WMIOBG : NO DATA IN STAGING ARRAY ***'/ &
1142 ' CALL WMIOBS FIRST '/)
1144 1002
FORMAT (/
' *** ERROR WMIOBG : INITIAL DATA NOT AT INITAL ', &
1147 1003
FORMAT (/
' *** ERROR WMIOBG : UNEXPECTED SIZE OF STAGING', &
1152 9000
FORMAT (
' TEST WMIOBG : GATHERING DATA FOR GRID ',i3)
1153 9001
FORMAT (
' TEST WMIOBG : NR. OF SPECTRA PER SOURCE GRID : '/ &
1155 9002
FORMAT (
' TEST WMIOBG : NO DATA NEEDED ON PROCESSOR')
1156 9003
FORMAT (
' TEST WMIOBG : NO DATA TO BE GATHERED')
1157 9004
FORMAT (
' TEST WMIOBG : DATA UP TO DATE')
1161 9010
FORMAT (
' TEST WMIOBG : TEST DATA AVAILABILITY')
1164 9011
FORMAT (
' MPIT WMIOBG : NBISTA =',i2)
1165 9012
FORMAT (
' STAGING ARRAY FROM',i4,1x,a)
1166 9013
FORMAT (
' VTIME, DTTST :',i9.8,i7.6,1x,f8.1)
1167 9014
FORMAT (/
' MPIT WMIOBG : RECEIVE FROM GRID',i4/ &
1168 ' +------+------+------+------+--------------+'/ &
1169 ' | IH | ID | FROM | TAG | handle err |'/ &
1170 ' +------+------+------+------+--------------+')
1171 9015
FORMAT (
' |',i5,
' | TIME |',2(i5,
' |'),i9,i4,
' |')
1172 9016
FORMAT (
' |',i5,
' |',i5,
' |',2(i5,
' |'),i9,i4,
' |')
1173 9017
FORMAT (
' +------+------+------+------+--------------+'/)
1174 9018
FORMAT (
' MPIT WMIOBG : NRQHGH:',i10/)
1175 9019
FORMAT (
' MPIT WMIOBG : RECEIVES FINISHED :',f6.1,
'%')
1176 9100
FORMAT (
' MPIT WMIOBG : CONVERTING SPECTRA FROM GRID',i3)
1180 9020
FORMAT (
' TEST WMIOBG : FILLING ABPI0/N AND TIMES')
1181 9021
FORMAT (
' TEST WMIOBG : NEXT VALID TIME FOR ABPIN:',i9.8,i7.6)
1182 9022
FORMAT (
' TEST WMIOBG : GETTING',i4,
' SPECTRA FROM GRID ', &
1183 i3,
' STORING AT ',i3/ &
1184 ' WEIGHTS : ',2f6.3)
1188 9030
FORMAT (
' TEST WMIOBG : DUMP DATA TO FILE')
1192 9040
FORMAT (
' TEST WMIOBG : FILLING BBPI0/N')
References w3odatmd::abpi0, w3odatmd::abpin, wmmdatmd::bcdump, wmmdatmd::bpstge, w3timemd::dsec21(), w3servmd::extcde(), w3gdatmd::fr1, w3odatmd::iaproc, wmmdatmd::improc, include(), wmmdatmd::init_get_jsea_isproc_glob(), wmmdatmd::mdatas, wmmdatmd::mdse, wmmdatmd::mdst, wmmdatmd::mpi_comm_mwave, wmmdatmd::mtag0, w3odatmd::napbpt, w3odatmd::naproc, w3odatmd::nbi, wmmdatmd::nbi2g, wmmdatmd::nbi2s, wmmdatmd::nbista, w3odatmd::nds, w3gdatmd::nk, wmmdatmd::nmperr, wmmdatmd::nmproc, wmmdatmd::nrgrd, w3gdatmd::nspec, w3gdatmd::nth, w3odatmd::outpts, wmmdatmd::respec, w3gdatmd::sgrds, w3servmd::strace(), w3odatmd::tbpi0, w3odatmd::tbpin, w3gdatmd::th, w3wdatmd::time, w3cspcmd::w3cspc(), w3iobcmd::w3iobc(), w3adatmd::w3seta(), w3gdatmd::w3setg(), w3odatmd::w3seto(), w3wdatmd::w3setw(), w3updtmd::w3ubpt(), and w3gdatmd::xfr.
Referenced by wminitmd::wminit(), wminitmd::wminitnml(), and wmwavemd::wmwave().
◆ wmiobs()
| subroutine wminiomd::wmiobs |
( |
integer, intent(in) |
IMOD | ) |
|
Stage internal boundary data in the data structure BPSTGE.
For the shared memory version, arrays are initialized and the data are copied. For the distributed memory version, the data are moved using a non-blocking send. In this case, the arrays are dimensioned on the receiving side.
- Parameters
-
| [in] | IMOD | Model number of grid from which data is to be staged. |
- Author
- H. L. Tolman
- Date
- 06-Jun-2018
Definition at line 105 of file wminiomd.F90.
206 INTEGER,
INTENT(IN) :: IMOD
211 INTEGER :: J, I, IOFF, ISEA, JSEA, IS
216 INTEGER :: IP, IT0, ITAG, IERR_MPI
217 INTEGER,
POINTER :: NRQ, IRQ(:)
220 INTEGER,
SAVE :: IENT = 0
222 REAL,
POINTER :: SBPI(:,:), TSTORE(:,:)
225 CALL strace (ient,
'WMIOBS')
232 WRITE (
mdst,9000) imod
236 IF ( sum(
nbi2g(:,imod)) .EQ. 0 )
RETURN
248 IF (
nbi2g(j,imod) .EQ. 0 ) cycle
252 IF ( imod .EQ. 1 )
THEN
255 ioff = sum(
nbi2g(j,1:imod-1))
266 IF (
bpstge(j,imod)%INIT )
THEN
267 IF (
SIZE(
bpstge(j,imod)%SBPI(:,1)) .NE.
nspec .OR. &
268 SIZE(
bpstge(j,imod)%SBPI(1,:)) &
269 .NE.
nbi2g(j,imod) )
THEN
270 DEALLOCATE (
bpstge(j,imod)%SBPI )
271 bpstge(j,imod)%INIT = .false.
277 IF ( .NOT.
bpstge(j,imod)%INIT )
THEN
281 bpstge(j,imod)%INIT = .true.
286 IF (
respec(j,imod) )
THEN
290 sbpi =>
bpstge(j,imod)%SBPI
302 nrq =>
bpstge(j,imod)%NRQBPS
303 sbpi =>
bpstge(j,imod)%TSTORE
331 IF ( itag .GT.
mtag1 )
THEN
336 IF (
allprc(ip,j) .NE. 0 .AND. &
339 CALL mpi_isend (
bpstge(j,imod)%STIME, 2, &
340 mpi_integer, ip-1, itag, &
357 DO i=1,
nbi2g(j,imod)
359 isea =
nbi2s(ioff+i,2)
365 IF ( isproc .NE.
iaproc ) cycle
369 sum(
nbi2g(j,1:imod-1))
373 sbpi(is,i) =
va(is,jsea) *
sig2(is) /
cg(1+(is-1)/
nth,isea)
378 IF (
allprc(ip,j) .NE. 0 .AND. &
382 IF ( itag .GT.
mtag1 )
THEN
386 CALL mpi_isend ( sbpi(1,i),
nspec, mpi_real, &
391 WRITE (
mdst,9082) nrq, jsea, ip, itag-
mtag0, &
403 WRITE (
mdst,9084) nrq
407 IF ( nrq .GT. 0 )
THEN
408 ALLOCATE (
bpstge(j,imod)%IRQBPS(nrq) )
409 bpstge(j,imod)%IRQBPS = irq(:nrq)
411 DEALLOCATE (
bpstge(j,imod)%TSTORE )
423 IF (
respec(j,imod) )
THEN
424 sbpi =>
bpstge(j,imod)%SBPI
429 DEALLOCATE ( tstore )
442 1001
FORMAT (/
' *** ERROR WMIOBS : REQUESTED MPI TAG EXCEEDS', &
443 ' UPPER BOUND (MTAG1) ***')
446 9000
FORMAT (
' TEST WMIOBS : STAGING DATA FROM GRID ',i3)
447 9001
FORMAT (
' TEST WMIOBS : NR. OF SPECTRA PER GRID : '/ &
452 9010
FORMAT (
' TEST WMIOBS : STAGING',i4,
' SPECTRA FROM GRID ', &
454 ' STARTING WITH SPECTRUM ',i4, &
459 9030
FORMAT (
' TEST WMIOBS : TIME :',i10.8,i7.6)
463 9080
FORMAT (/
' MPIT WMIOBS: COMMUNICATION CALLS '/ &
464 ' +------+------+------+------+--------------+'/ &
465 ' | IH | ID | TARG | TAG | handle err |'/ &
466 ' +------+------+------+------+--------------+')
467 9081
FORMAT (
' |',i5,
' | TIME |',2(i5,
' |'),i9,i4,
' |')
468 9082
FORMAT (
' |',i5,
' |',i5,
' |',2(i5,
' |'),i9,i4,
' |')
469 9083
FORMAT (
' +------+------+------+------+--------------+')
470 9084
FORMAT (
' MPIT WMIOBS: NRQBPT:',i10/)
References wmmdatmd::allprc, wmmdatmd::bpstge, w3adatmd::cg, w3servmd::extcde(), w3gdatmd::fr1, w3odatmd::iaproc, include(), w3parall::init_get_jsea_isproc(), wmmdatmd::mdse, wmmdatmd::mdst, wmmdatmd::mpi_comm_mwave, wmmdatmd::mtag0, wmmdatmd::mtag1, w3odatmd::naproc, wmmdatmd::nbi2g, wmmdatmd::nbi2s, w3gdatmd::nk, wmmdatmd::nmproc, wmmdatmd::nrgrd, w3gdatmd::nspec, w3gdatmd::nth, w3odatmd::outpts, wmmdatmd::respec, w3gdatmd::sgrds, w3gdatmd::sig2, w3servmd::strace(), w3gdatmd::th, w3wdatmd::time, w3wdatmd::va, w3cspcmd::w3cspc(), w3adatmd::w3seta(), w3gdatmd::w3setg(), w3odatmd::w3seto(), w3wdatmd::w3setw(), wmmdatmd::wmsetm(), and w3gdatmd::xfr.
Referenced by wminitmd::wminit(), wminitmd::wminitnml(), and wmwavemd::wmwave().
◆ wmioef()
| subroutine wminiomd::wmioef |
( |
integer, intent(in) |
IMOD | ) |
|
Finalize staging of internal same-rank data in the data structure EQSTGE (MPI only).
Post appropriate 'wait' functions to assure that the communication has finished.
- Parameters
-
| [in] | IMOD | Model number of grid from which data has been staged. |
- Author
- H. L. Tolman
- Date
- 25-May-2006
Definition at line 3399 of file wminiomd.F90.
3477 INTEGER,
INTENT(IN) :: IMOD
3485 INTEGER,
POINTER :: NRQ, IRQ(:)
3486 INTEGER,
ALLOCATABLE :: STATUS(:,:)
3489 INTEGER,
SAVE :: IENT = 0
3493 CALL strace (ient,
'WMIOEF')
3500 WRITE (
mdst,9000) imod
3509 nrq =>
eqstge(j,imod)%NRQEQS
3515 IF ( nrq .EQ. 0 ) cycle
3516 irq =>
eqstge(j,imod)%IRQEQS
3522 ALLOCATE (
status(mpi_status_size,nrq) )
3523 CALL mpi_waitall ( nrq, irq,
status, ierr_mpi )
3530 DEALLOCATE (
eqstge(j,imod)%IRQEQS, &
3547 9000
FORMAT (
' TEST WMIOEF : FINALIZE STAGING DATA FROM GRID ',i3)
3548 9010
FORMAT (
' TEST WMIOEF : FINISHED WITH TARGET ',i3)
References wmmdatmd::eqstge, include(), wmmdatmd::mdst, wmmdatmd::nrgrd, and w3servmd::strace().
Referenced by wmwavemd::wmwave().
◆ wmioeg()
| subroutine wminiomd::wmioeg |
( |
integer, intent(in) |
IMOD, |
|
|
logical, intent(out), optional |
DONE |
|
) |
| |
Gather internal same-rank data for a given model.
For distributed memory version first receive all staged data. After staged data is present, average, convert as necessary, and store in basic spectral arrays.
Using storage array EQSTGE and time stamps.
- Parameters
-
| [in] | IMOD | Model number of grid from which data is to be gathered. |
| [out] | DONE | Flag for completion of operation (opt). |
- Author
- H. L. Tolman
- Date
- 22-Jan-2007
Definition at line 2820 of file wminiomd.F90.
2921 INTEGER,
INTENT(IN) :: IMOD
2922 LOGICAL,
INTENT(OUT),
OPTIONAL :: DONE
2927 INTEGER :: J, I, ISEA, JSEA, IA, IS
2929 INTEGER,
SAVE :: IENT = 0
2932 INTEGER :: IT0, ITAG, IFROM, IERR_MPI, &
2938 INTEGER,
POINTER :: VTIME(:)
2940 INTEGER,
POINTER :: NRQ, IRQ(:), STATUS(:,:)
2943 REAL,
POINTER :: SPEC1(:,:), SPEC2(:,:), SPEC(:,:)
2945 REAL,
POINTER :: SEQL(:,:,:)
2951 CALL strace (ient,
'WMIOEG')
2958 WRITE (
mdst,9000) imod
2959 WRITE (
mdst,9001)
'NREC',
eqstge(imod,:)%NREC
2962 IF (
PRESENT(done) ) done = .false.
2964 IF (
eqstge(imod,imod)%NREC .EQ. 0 )
THEN
2965 IF (
PRESENT(done) ) done = .true.
2991 IF ( imod .EQ. j ) cycle
2992 IF (
eqstge(imod,j)%NREC .EQ. 0 ) cycle
2996 vtime =>
eqstge(imod,j)%VTIME
2997 IF ( vtime(1) .EQ. -1 )
RETURN
2999 IF ( dttst .NE. 0. )
RETURN
3017 IF (
eqlsta(imod) .EQ. 0 )
THEN
3021 nrq =>
mdatas(imod)%NRQEQG
3024 IF ( j .EQ. imod ) cycle
3025 nrq = nrq +
eqstge(imod,j)%NREC * &
3028 ALLOCATE ( irq(nrq) )
3035 IF ( imod .EQ. j ) cycle
3036 IF (
eqstge(imod,j)%NREC .EQ. 0 ) cycle
3042 vtime =>
eqstge(imod,j)%VTIME
3043 IF ( vtime(1) .EQ. -1 )
THEN
3050 WRITE (
mdst,9013) vtime, dttst
3056 IF ( dttst .NE. 0. )
THEN
3066 seql =>
eqstge(imod,j)%SEQL
3070 DO i=1,
eqstge(imod,j)%NREC
3071 jsea =
eqstge(imod,j)%JSEA(i)
3072 na =
eqstge(imod,j)%NAVG(i)
3074 ip =
eqstge(imod,j)%RIP(i,ia)
3075 itag =
eqstge(imod,j)%RTG(i,ia) + it0
3076 IF ( ip .NE.
improc )
THEN
3078 CALL mpi_irecv ( seql(1,i,ia), &
3079 sgrds(j)%NSPEC, mpi_real, &
3081 irq(nrq), ierr_mpi )
3084 WRITE (
mdst,9016) nrq, jsea, ip, &
3085 itag-
mtag2, irq(nrq), ierr_mpi
3108 WRITE (
mdst,9018) nrq
3112 IF ( nrq .NE. 0 )
THEN
3113 ALLOCATE (
mdatas(imod)%IRQEQG(nrq) )
3114 mdatas(imod)%IRQEQG = irq(1:nrq)
3125 IF ( nrq .GT. 0 )
THEN
3146 IF (
eqlsta(imod) .EQ. 1 )
THEN
3150 nrq =>
mdatas(imod)%NRQEQG
3151 irq =>
mdatas(imod)%IRQEQG
3152 ALLOCATE (
status(mpi_status_size,nrq) )
3158 IF (
PRESENT(done) )
THEN
3162 CALL mpi_testall ( nrq, irq, flagok,
status, &
3169 CALL mpi_test ( irq(i), flag,
status(1,1), &
3171 flagok = flagok .AND. flag
3172 IF ( flag ) icount = icount + 1
3174 WRITE (
mdst,9019) 100. * real(icount) / real(nrq)
3182 CALL mpi_waitall ( nrq, irq,
status, ierr_mpi )
3186 WRITE (
mdst,9019) 100.
3201 IF ( nrq.NE.0 )
DEALLOCATE (
mdatas(imod)%IRQEQG )
3224 IF ( j .EQ. imod ) cycle
3225 DO is=1,
eqstge(imod,j)%NRQOUT
3226 i =
eqstge(imod,j)%OUTDAT(is,1)
3227 i1 =
eqstge(imod,j)%OUTDAT(is,2)
3228 i2 =
eqstge(imod,j)%OUTDAT(is,3)
3229 eqstge(imod,j)%SEQL(:,i1,i2) =
eqstge(imod,j)%TSTORE(:,i)
3244 WRITE (
mdst,9021) imod,
eqstge(imod,imod)%NREC
3247 DO i=1,
eqstge(imod,imod)%NREC
3248 jsea =
eqstge(imod,imod)%JSEA(i)
3249 wght =
eqstge(imod,imod)%WGHT(i)
3250 va(:,jsea) = wght *
va(:,jsea)
3256 IF ( imod.EQ.j .OR.
eqstge(imod,j)%NREC.EQ.0 ) cycle
3265 DO i=1,
eqstge(imod,j)%NREC
3266 jsea =
eqstge(imod,j)%JSEA(i)
3267 va(:,jsea) =
eqstge(imod,j)%SEQL(:,i,1)
3278 ALLOCATE ( spec1(
sgrds(j)%NSPEC,
eqstge(imod,j)%NREC) )
3281 DO i=1,
eqstge(imod,j)%NREC
3282 DO ia=1,
eqstge(imod,j)%NAVG(i)
3283 spec1(:,i) = spec1(:,i) +
eqstge(imod,j)%SEQL(:,i,ia) * &
3284 eqstge(imod,j)%WAVG(i,ia)
3290 IF (
respec(imod,j) )
THEN
3308 DO i=1,
eqstge(imod,j)%NREC
3309 isea =
eqstge(imod,j)%ISEA(i)
3310 jsea =
eqstge(imod,j)%JSEA(i)
3311 wght =
eqstge(imod,j)%WGHT(i)
3315 va(:,jsea) = spec(:,i)
3319 va(is,jsea) =
va(is,jsea) + wght * &
3320 spec(is,i) /
sig2(is) *
cg(1+(is-1)/
nth,isea)
3329 DEALLOCATE ( spec1 )
3330 IF (
respec(imod,j) )
DEALLOCATE ( spec2 )
3343 IF (
PRESENT(done) ) done = .true.
3352 9000
FORMAT (
' TEST WMIOEG : GATHERING DATA FOR GRID ',i4)
3353 9001
FORMAT (
' TEST WMIOEG : ',a,
' PER SOURCE GRID : '/13x,20i5)
3354 9002
FORMAT (
' TEST WMIOEG : NO DATA TO BE GATHERED')
3358 9010
FORMAT (
' TEST WMIOEG : TEST DATA AVAILABILITY FOR',i9.8,i7.6)
3361 9011
FORMAT (
' MPIT WMIOEG : EQLSTA =',i2)
3362 9012
FORMAT (
' STAGING ARRAY FROM',i4,1x,a)
3363 9013
FORMAT (
' VTIME, DTTST :',i9.8,i7.6,1x,f8.1)
3364 9014
FORMAT (/
' MPIT WMIOEG : RECEIVE FROM GRID',i4/ &
3365 ' +------+------+------+------+--------------+'/ &
3366 ' | IH | ID | FROM | TAG | handle err |'/ &
3367 ' +------+------+------+------+--------------+')
3368 9016
FORMAT (
' |',i5,
' |',i5,
' |',2(i5,
' |'),i9,i4,
' |')
3369 9017
FORMAT (
' +------+------+------+------+--------------+'/)
3370 9018
FORMAT (
' MPIT WMIOEG : NRQBPT:',i10/)
3371 9019
FORMAT (
' MPIT WMIOEG : RECEIVES FINISHED :',f6.1,
'%')
3375 9020
FORMAT (
' TEST WMIOEG : PROCESSING DATA GRID BY GRID')
3376 9021
FORMAT (
' NATIVE GRID ',i3,
' DATA :',i6)
3377 9022
FORMAT (
' RECEIVING GRID ',i3,
' DATA :',i6)
3378 9023
FORMAT (
' AVERAGE SPECTRA')
3379 9024
FORMAT (
' CONVERTING SPECTRA')
References w3adatmd::cg, w3timemd::dsec21(), wmmdatmd::eqlsta, wmmdatmd::eqstge, w3servmd::extcde(), w3gdatmd::fachfe, w3gdatmd::fr1, w3gdatmd::gtype, wmmdatmd::improc, include(), wmmdatmd::mdatas, wmmdatmd::mdse, wmmdatmd::mdst, wmmdatmd::mpi_comm_mwave, wmmdatmd::mtag2, wmmdatmd::ngrpsmc, w3gdatmd::nk, yownodepool::npa, wmmdatmd::nrgrd, w3gdatmd::nspec, w3gdatmd::nth, yowexchangemodule::pdlib_exchange2dreal_zero(), wmmdatmd::respec, w3gdatmd::sgrds, w3gdatmd::sig2, w3gdatmd::smctype, w3servmd::strace(), w3gdatmd::th, w3wdatmd::time, w3wdatmd::va, w3cspcmd::w3cspc(), w3adatmd::w3seta(), w3gdatmd::w3setg(), w3odatmd::w3seto(), w3wdatmd::w3setw(), and w3gdatmd::xfr.
Referenced by wmwavemd::wmwave().
◆ wmioes()
| subroutine wminiomd::wmioes |
( |
integer, intent(in) |
IMOD | ) |
|
Stage internal same-rank data in the data structure EQSTGE.
Directly fill staging arrays in shared memory version, or post the corresponding sends in distributed memory version.
- Parameters
-
| [in] | IMOD | Model number of grid from which data is to be staged. |
- Author
- H. L. Tolman
- Date
- 28-Sep-2016
Definition at line 2493 of file wminiomd.F90.
2586 INTEGER,
INTENT(IN) :: IMOD
2591 INTEGER :: J, NR, I, ISEA, JSEA, IS, I1, I2
2593 INTEGER :: IT0, ITAG, IP, IERR_MPI
2596 INTEGER,
SAVE :: IENT = 0
2599 INTEGER,
POINTER :: NRQ, IRQ(:), NRQOUT, OUTDAT(:,:)
2602 REAL,
POINTER :: SEQL(:,:,:)
2605 REAL,
POINTER :: SEQL(:,:)
2609 CALL strace (ient,
'WMIOES')
2616 WRITE (
mdst,9000) imod
2630 IF ( j .EQ. imod ) cycle
2634 IF (
nr .EQ. 0 )
THEN
2641 IF (
nr .EQ. 0 ) cycle
2651 seql =>
eqstge(j,imod)%SEQL
2655 seql =>
eqstge(j,imod)%TSTORE
2659 ALLOCATE (
eqstge(j,imod)%IRQEQS(
nr) , &
2664 nrq =>
eqstge(j,imod)%NRQEQS
2665 nrqout =>
eqstge(j,imod)%NRQOUT
2666 irq =>
eqstge(j,imod)%IRQEQS
2667 outdat =>
eqstge(j,imod)%OUTDAT
2698 isea =
eqstge(j,imod)%SIS(i)
2699 jsea =
eqstge(j,imod)%SJS(i)
2700 i1 =
eqstge(j,imod)%SI1(i)
2701 i2 =
eqstge(j,imod)%SI2(i)
2703 ip =
eqstge(j,imod)%SIP(i)
2704 itag =
eqstge(j,imod)%STG(i) + it0
2717 seql(:, i) =
va(:, jsea)
2723 seql(is,i1,i2) =
va(is,jsea) *
sig2(is) &
2724 /
cg(1+(is-1)/
nth,isea)
2727 seql( is,i ) =
va(is,jsea) *
sig2(is) &
2728 /
cg(1+(is-1)/
nth,isea)
2738 IF ( ip .NE.
improc )
THEN
2740 CALL mpi_isend ( seql(1,i),
nspec, mpi_real, ip-1, &
2744 WRITE (
mdst,9082) nrq, jsea, ip, itag-
mtag2, &
2750 outdat(nrqout,1) = i
2751 outdat(nrqout,2) = i1
2752 outdat(nrqout,3) = i2
2760 WRITE (
mdst,9084) nrq
2770 1001
FORMAT (/
' *** ERROR WMIOES : REQUESTED MPI TAG EXCEEDS', &
2771 ' UPPER BOUND (MTAG_UB) ***')
2774 9000
FORMAT (
' TEST WMIOES : STAGING DATA FROM GRID ',i3)
2775 9001
FORMAT (
' TEST WMIOES : NR. OF SPECTRA PER GRID : '/ &
2780 9010
FORMAT (
' TEST WMIOES : POSTING DATA TO GRID ',i3, &
2782 9011
FORMAT (
' TEST WMIOES : POSTING DATA TO GRID ',i3, &
2783 ' NR = ',i6,
' TIME GAP = ',f8.1)
2787 9030
FORMAT (
' TEST WMIOES : TIME :',i10.8,i7.6)
2791 9080
FORMAT (/
' MPIT WMIOES: COMMUNICATION CALLS '/ &
2792 ' +------+------+------+------+--------------+'/ &
2793 ' | IH | ID | TARG | TAG | handle err |'/ &
2794 ' +------+------+------+------+--------------+')
2795 9082
FORMAT (
' |',i5,
' |',i5,
' |',2(i5,
' |'),i9,i4,
' |')
2796 9083
FORMAT (
' +------+------+------+------+--------------+')
2797 9084
FORMAT (
' MPIT WMIOES: NRQEQS:',i10/)
References w3adatmd::cg, w3timemd::dsec21(), wmmdatmd::eqstge, w3servmd::extcde(), w3gdatmd::gtype, wmmdatmd::improc, include(), wmmdatmd::mdse, wmmdatmd::mdst, wmmdatmd::mpi_comm_mwave, wmmdatmd::mtag2, wmmdatmd::mtag_ub, wmmdatmd::nrgrd, w3gdatmd::nspec, w3gdatmd::nth, w3gdatmd::sig2, w3gdatmd::smctype, w3odatmd::stop, w3servmd::strace(), w3wdatmd::time, wmmdatmd::tsync, w3wdatmd::va, w3adatmd::w3seta(), w3gdatmd::w3setg(), w3odatmd::w3seto(), and w3wdatmd::w3setw().
Referenced by wmwavemd::wmwave().
◆ wmiohf()
| subroutine wminiomd::wmiohf |
( |
integer, intent(in) |
IMOD | ) |
|
Finalize staging of internal high-to-low data in the data structure HGSTGE (MPI only).
Post appropriate 'wait' functions to assure that the communication has finished.
- Parameters
-
| [in] | IMOD | Model number of grid from which data has been staged. |
- Author
- H. L. Tolman
- Date
- 16-Jan-2006
Definition at line 2325 of file wminiomd.F90.
2403 INTEGER,
INTENT(IN) :: IMOD
2411 INTEGER,
POINTER :: NRQ, IRQ(:)
2412 INTEGER,
ALLOCATABLE :: STATUS(:,:)
2415 INTEGER,
SAVE :: IENT = 0
2419 CALL strace (ient,
'WMIOHF')
2426 WRITE (
mdst,9000) imod
2435 nrq =>
hgstge(j,imod)%NRQHGS
2441 IF ( nrq .EQ. 0 ) cycle
2442 irq =>
hgstge(j,imod)%IRQHGS
2448 ALLOCATE (
status(mpi_status_size,nrq) )
2449 CALL mpi_waitall ( nrq, irq,
status, ierr_mpi )
2457 DEALLOCATE (
hgstge(j,imod)%IRQHGS, &
2473 9000
FORMAT (
' TEST WMIOHF : FINALIZE STAGING DATA FROM GRID ',i3)
2474 9010
FORMAT (
' TEST WMIOHF : FINISHED WITH TARGET ',i3)
References wmmdatmd::hgstge, include(), wmmdatmd::mdst, wmmdatmd::nrgrd, and w3servmd::strace().
Referenced by wmwavemd::wmwave().
◆ wmiohg()
| subroutine wminiomd::wmiohg |
( |
integer, intent(in) |
IMOD, |
|
|
logical, intent(out), optional |
DONE |
|
) |
| |
Gather internal high-to-low data for a given model.
For distributed memory version first receive all staged data. After staged data is present, average, convert as necessary, and store in basic spectral arrays.
Using storage array HGSTAGE and time stamps.
- Parameters
-
| [in] | IMOD | Model number of grid from which data is to be gathered. |
| [out] | DONE | Flag for completion of operation (opt). |
- Author
- H. L. Tolman
- Date
- 20-Dec-2006
Definition at line 1724 of file wminiomd.F90.
1825 INTEGER,
INTENT(IN) :: IMOD
1826 LOGICAL,
INTENT(OUT),
OPTIONAL :: DONE
1831 INTEGER :: NTOT, J, IS, NA, IA, JSEA, ISEA, I
1833 INTEGER :: ITAG, IT0, IFROM, ILOC, NLOC, &
1834 ISPROC, IERR_MPI, ICOUNT, &
1838 INTEGER,
SAVE :: IENT = 0
1840 INTEGER,
POINTER :: VTIME(:)
1842 INTEGER,
POINTER :: NRQ, IRQ(:), STATUS(:,:)
1845 REAL,
POINTER :: SPEC1(:,:), SPEC2(:,:), SPEC(:,:)
1847 REAL,
POINTER :: SHGH(:,:,:)
1858 CALL strace (ient,
'WMIOHG')
1864 IF (
toutp(1,imod) .EQ. -1 )
THEN
1874 ELSE IF ( dttst .EQ. 0. )
THEN
1881 WRITE (
mdst,9000) imod, dttst, flgall
1888 ntot = sum(
hgstge(imod,:)%NREC)
1893 ntot = sum(
hgstge(imod,:)%NRC1)
1896 IF (
PRESENT(done) ) done = .false.
1898 IF ( ntot .EQ. 0 )
THEN
1899 IF (
PRESENT(done) ) done = .true.
1926 ntot =
hgstge(imod,j)%NREC
1928 ntot =
hgstge(imod,j)%NRC1
1930 IF ( ntot .EQ. 0 ) cycle
1934 vtime =>
hgstge(imod,j)%VTIME
1935 IF ( vtime(1) .EQ. -1 )
RETURN
1937 IF ( dttst .NE. 0. )
RETURN
1955 IF (
hghsta(imod) .EQ. 0 )
THEN
1959 nrq =>
mdatas(imod)%NRQHGG
1963 nrq = nrq +
hgstge(imod,j)%NREC * &
1966 nrq = nrq +
hgstge(imod,j)%NRC1 * &
1971 ALLOCATE ( irq(nrq) )
1978 IF (
hgstge(imod,j)%NTOT .EQ. 0 ) cycle
1984 vtime =>
hgstge(imod,j)%VTIME
1985 IF ( vtime(1) .EQ. -1 )
THEN
1992 WRITE (
mdst,9013) vtime, dttst
1998 IF ( dttst .NE. 0. )
THEN
2008 shgh =>
hgstge(imod,j)%SHGH
2013 ntot =
hgstge(imod,j)%NREC
2015 ntot =
hgstge(imod,j)%NRC1
2023 jsea =
hgstge(imod,j)%LJSEA(i)
2026 nloc =
hgstge(imod,j)%NRAVG(i)
2028 isproc =
hgstge(imod,j)%IMPSRC(i,iloc)
2029 itag =
hgstge(imod,j)%ITAG(i,iloc) + it0
2030 IF ( isproc .NE.
improc )
THEN
2032 CALL mpi_irecv ( shgh(1,iloc,i), &
2033 sgrds(j)%NSPEC, mpi_real, &
2035 irq(nrq), ierr_mpi )
2038 WRITE (
mdst,9016) nrq, jsea, isproc, &
2039 itag-
mtag1, irq(nrq), ierr_mpi
2062 WRITE (
mdst,9018) nrq
2066 ALLOCATE (
mdatas(imod)%IRQHGG(nrq) )
2067 mdatas(imod)%IRQHGG = irq(1:nrq)
2074 IF ( nrq .GT. 0 )
THEN
2095 IF (
hghsta(imod) .EQ. 1 )
THEN
2099 nrq =>
mdatas(imod)%NRQHGG
2100 irq =>
mdatas(imod)%IRQHGG
2101 ALLOCATE (
status(mpi_status_size,nrq) )
2107 IF (
PRESENT(done) )
THEN
2111 CALL mpi_testall ( nrq, irq, flagok,
status, &
2118 CALL mpi_test ( irq(i), flag,
status(1,1), &
2120 flagok = flagok .AND. flag
2121 IF ( flag ) icount = icount + 1
2123 WRITE (
mdst,9019) 100. * real(icount) / real(nrq)
2131 CALL mpi_waitall ( nrq, irq,
status, ierr_mpi )
2135 WRITE (
mdst,9019) 100.
2151 DEALLOCATE (
mdatas(imod)%IRQHGG )
2173 IF ( j .EQ. imod ) cycle
2174 DO is=1,
hgstge(imod,j)%NRQOUT
2175 i0 =
hgstge(imod,j)%OUTDAT(is,1)
2176 i2 =
hgstge(imod,j)%OUTDAT(is,2)
2177 i1 =
hgstge(imod,j)%OUTDAT(is,3)
2178 hgstge(imod,j)%SHGH(:,i2,i1) =
hgstge(imod,j)%TSTORE(:,i0)
2195 ntot =
hgstge(imod,j)%NREC
2197 ntot =
hgstge(imod,j)%NRC1
2199 IF ( ntot .EQ. 0 ) cycle
2202 WRITE (
mdst,9021) j, ntot
2207 IF (
respec(imod,j) )
THEN
2208 ALLOCATE ( spec1(
sgrds(j)%NSPEC,ntot), spec2(
nspec,ntot) )
2211 ALLOCATE ( spec2(
nspec,ntot) )
2222 na =
hgstge(imod,j)%NRAVG(is)
2223 wgth =
hgstge(imod,j)%WGTH(is,1)
2224 spec(:,is) = wgth *
hgstge(imod,j)%SHGH(:,1,is)
2226 wgth =
hgstge(imod,j)%WGTH(is,ia)
2227 spec(:,is) = spec(:,is) + wgth*
hgstge(imod,j)%SHGH(:,ia,is)
2233 IF (
respec(imod,j) )
THEN
2243 DEALLOCATE ( spec1 )
2254 jsea =
hgstge(imod,j)%LJSEA(is)
2257 va(i,jsea) = spec2(i,is) /
sig2(i) *
cg(1+(i-1)/
nth,isea)
2261 DEALLOCATE ( spec2 )
2268 IF (
PRESENT(done) ) done = .true.
2277 9000
FORMAT (
' TEST WMIOHG : GATHERING DATA FOR GRID ',i3/ &
2278 ' DTOUTP, FLGALL :',f8.1,l4)
2279 9001
FORMAT (
' TEST WMIOHG : NR. OF SPECTRA PER SOURCE GRID : '/ &
2281 9003
FORMAT (
' TEST WMIOHG : NO DATA TO BE GATHERED')
2285 9010
FORMAT (
' TEST WMIOHG : TEST DATA AVAILABILITY FOR',i9.8,i7.6)
2288 9011
FORMAT (
' MPIT WMIOHG : HGHSTA =',i2)
2289 9013
FORMAT (
' VTIME, DTTST :',i9.8,i7.6,1x,f8.1)
2290 9014
FORMAT (/
' MPIT WMIOHG : RECEIVE FROM GRID',i4/ &
2291 ' +------+------+------+------+--------------+'/ &
2292 ' | IH | ID | FROM | TAG | handle err |'/ &
2293 ' +------+------+------+------+--------------+')
2294 9016
FORMAT (
' |',i5,
' |',i5,
' |',2(i5,
' |'),i9,i4,
' |')
2295 9017
FORMAT (
' +------+------+------+------+--------------+'/)
2296 9018
FORMAT (
' MPIT WMIOHG : NRQBPT:',i10/)
2297 9019
FORMAT (
' MPIT WMIOHG : RECEIVES FINISHED :',f6.1,
'%')
2301 9020
FORMAT (
' TEST WMIOHG : PROCESSING DATA GRID BY GRID')
2302 9021
FORMAT (
' FROM GRID ',i3,
' NR OF SPECTRA :',i6)
2303 9022
FORMAT (
' AVERAGE SPECTRA TO TEMP STORAGE')
2304 9023
FORMAT (
' CONVERT SPECTRAL GRID')
2305 9024
FORMAT (
' MOVE SPECTRA TO PERMANENT STORAGE')
References w3adatmd::cg, w3timemd::dsec21(), w3gdatmd::fachfe, wmmdatmd::flghg1, wmmdatmd::flghg2, w3gdatmd::fr1, wmmdatmd::hghsta, wmmdatmd::hgstge, wmmdatmd::improc, include(), w3parall::init_get_isea(), wmmdatmd::mdatas, wmmdatmd::mdse, wmmdatmd::mdst, wmmdatmd::mpi_comm_mwave, wmmdatmd::mtag1, w3gdatmd::nk, yownodepool::npa, wmmdatmd::nrgrd, w3gdatmd::nspec, w3gdatmd::nth, yowexchangemodule::pdlib_exchange2dreal_zero(), wmmdatmd::respec, w3gdatmd::sgrds, w3gdatmd::sig2, w3servmd::strace(), w3gdatmd::th, w3wdatmd::time, wmmdatmd::toutp, w3wdatmd::va, w3cspcmd::w3cspc(), w3adatmd::w3seta(), w3gdatmd::w3setg(), w3odatmd::w3seto(), w3wdatmd::w3setw(), w3wdatmd::wdatas, and w3gdatmd::xfr.
Referenced by wmwavemd::wmwave().
◆ wmiohs()
| subroutine wminiomd::wmiohs |
( |
integer, intent(in) |
IMOD | ) |
|
Stage internal high-to-low data in the data structure HGSTGE.
Directly fill staging arrays in shared memory version, or post the corresponding sends in distributed memory version.
- Parameters
-
| [in] | IMOD | Model number of grid from which data is to be staged. |
- Author
- H. L. Tolman
- Date
- 28-Sep-2016
Definition at line 1384 of file wminiomd.F90.
1477 INTEGER,
INTENT(IN) :: IMOD
1482 INTEGER :: J, NR, I, JSEA, ISEA, IS
1484 INTEGER :: ITAG, IP, IT0, IERR_MPI
1488 INTEGER,
SAVE :: IENT = 0
1491 INTEGER,
POINTER :: NRQ, IRQ(:), NRQOUT, OUTDAT(:,:)
1495 REAL,
POINTER :: SHGH(:,:,:)
1498 REAL,
POINTER :: SHGH(:,:)
1502 CALL strace (ient,
'WMIOHS')
1516 IF ( sum(
hgstge(:,imod)%NSND) .EQ. 0 )
RETURN
1521 IF ( sum(
hgstge(:,imod)%NSN1) .EQ. 0 )
RETURN
1534 IF ( j .EQ. imod ) cycle
1541 IF (
toutp(1,j) .EQ. -1 )
THEN
1546 IF ( dtoutp .EQ. 0. )
THEN
1554 IF (
nr .EQ. 0 )
THEN
1561 IF (
nr .EQ. 0 ) cycle
1568 shgh =>
hgstge(j,imod)%SHGH
1572 shgh =>
hgstge(j,imod)%TSTORE
1576 ALLOCATE (
hgstge(j,imod)%IRQHGS(
nr) )
1577 ALLOCATE (
hgstge(j,imod)%OUTDAT(
nr,3) )
1581 nrq =>
hgstge(j,imod)%NRQHGS
1582 nrqout =>
hgstge(j,imod)%NRQOUT
1583 irq =>
hgstge(j,imod)%IRQHGS
1584 outdat =>
hgstge(j,imod)%OUTDAT
1614 jsea =
hgstge(j,imod)%ISEND(i,1)
1617 ip =
hgstge(j,imod)%ISEND(i,2)
1619 i1 =
hgstge(j,imod)%ISEND(i,3)
1620 i2 =
hgstge(j,imod)%ISEND(i,4)
1622 itag =
hgstge(j,imod)%ISEND(i,5) + it0
1623 IF ( itag .GT.
mtag2 )
THEN
1631 shgh(is,i2,i1) =
va(is,jsea) *
sig2(is) &
1632 /
cg(1+(is-1)/
nth,isea)
1635 shgh( is,i ) =
va(is,jsea) *
sig2(is) &
1636 /
cg(1+(is-1)/
nth,isea)
1641 IF ( ip .NE.
improc )
THEN
1643 CALL mpi_isend ( shgh(1,i),
nspec, mpi_real, ip-1, &
1647 WRITE (
mdst,9082) nrq, jsea, ip, itag-
mtag1, &
1653 outdat(nrqout,1) = i
1654 outdat(nrqout,2) = i2
1655 outdat(nrqout,3) = i1
1663 WRITE (
mdst,9084) nrq
1673 1001
FORMAT (/
' *** ERROR WMIOHS : REQUESTED MPI TAG EXCEEDS', &
1674 ' UPPER BOUND (MTAG2) ***')
1677 9000
FORMAT (
' TEST WMIOHS : STAGING DATA FROM GRID ',i3, &
1679 9001
FORMAT (
' TEST WMIOHS : NR. OF SPECTRA PER GRID : '/ &
1684 9010
FORMAT (
' TEST WMIOHS : POSTING DATA TO GRID ',i3, &
1686 9011
FORMAT (
' TEST WMIOHS : POSTING DATA TO GRID ',i3, &
1687 ' NR = ',i6,
' TIME GAP = ',2f8.1)
1691 9030
FORMAT (
' TEST WMIOHS : TIME :',i10.8,i7.6)
1695 9080
FORMAT (/
' MPIT WMIOHS: COMMUNICATION CALLS '/ &
1696 ' +------+------+------+------+--------------+'/ &
1697 ' | IH | ID | TARG | TAG | handle err |'/ &
1698 ' +------+------+------+------+--------------+')
1699 9082
FORMAT (
' |',i5,
' |',i5,
' |',2(i5,
' |'),i9,i4,
' |')
1700 9083
FORMAT (
' +------+------+------+------+--------------+')
1701 9084
FORMAT (
' MPIT WMIOHS: NRQHGS:',i10/)
References w3adatmd::cg, w3timemd::dsec21(), w3servmd::extcde(), wmmdatmd::flghg1, wmmdatmd::flghg2, wmmdatmd::hgstge, wmmdatmd::improc, include(), w3parall::init_get_isea(), wmmdatmd::mdse, wmmdatmd::mdst, wmmdatmd::mpi_comm_mwave, wmmdatmd::mtag1, wmmdatmd::mtag2, wmmdatmd::nrgrd, w3gdatmd::nspec, w3gdatmd::nth, w3gdatmd::sig2, w3servmd::strace(), w3wdatmd::time, wmmdatmd::toutp, wmmdatmd::tsync, w3wdatmd::va, w3adatmd::w3seta(), w3gdatmd::w3setg(), w3odatmd::w3seto(), and w3wdatmd::w3setw().
Referenced by wmwavemd::wmwave().
integer, dimension(:,:), pointer nbi2s
NBI2S.
logical, dimension(:,:), allocatable respec
RESPEC.
integer, dimension(:), pointer tbpi0
real function dsec21(TIME1, TIME2)
cmake src_list cmake include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/check_switches.cmake) check_switches("$
Define data structures to set up wave model auxiliary data for several models simultaneously.
type(sgrd), dimension(:), allocatable, target sgrds
subroutine init_get_jsea_isproc_glob(ISEA, J, JSEA, ISPROC)
Introduce mapping for ISPROC and JSEA when using PDLIB in the Multigrid approach.
Define data structures to set up wave model dynamic data for several models simultaneously.
real, dimension(:,:), pointer cg
type(hgst), dimension(:,:), allocatable, target hgstge
HGSTGE.
integer, dimension(:,:), allocatable tsync
TSYNC.
type(wdata), dimension(:), allocatable, target wdatas
Bundles all input updating routines for WAVEWATCH III.
integer, dimension(:), pointer time
integer, dimension(:), allocatable nbista
NBISTA.
subroutine, public pdlib_exchange2dreal_zero(U)
integer, dimension(:), allocatable hghsta
HGHSTA.
subroutine w3ubpt
Update spectra at the active boundary points.
real, dimension(:,:), pointer abpin
logical, dimension(:), allocatable bcdump
BCDUMP.
integer, dimension(:), pointer tbpin
Convert spectra to new discrete spectral grid.
integer, public npa
number of ghost + resident nodes this partition holds
real, dimension(:,:), pointer va
subroutine w3iobc(INXOUT, NDSB, TIME1, TIME2, IOTST, IMOD)
Write/read boundary conditions file(s).
real, dimension(:), pointer th
integer, parameter mtag2
MTAG2.
subroutine w3setg(IMOD, NDSE, NDST)
character(len=8), dimension(max_timers), save status
integer, dimension(:,:), allocatable toutp
TOUTP.
subroutine w3seta(IMOD, NDSE, NDST)
Select one of the WAVEWATCH III grids / models.
type(mdata), dimension(:), allocatable, target mdatas
MDATAS.
Has data that belong to nodes.
integer, dimension(:,:), allocatable nbi2g
NBI2G.
subroutine w3setw(IMOD, NDSE, NDST)
Select one of the WAVEWATCH III grids / models.
integer, parameter mtag_ub
MPI_TAG_UB on Cray XC40.
subroutine w3seto(IMOD, NDSERR, NDSTST)
type(eqst), dimension(:,:), allocatable, target eqstge
EQSTGE.
integer, dimension(:), pointer nds
Processing of boundary data output.
subroutine w3cspc(SP1, NFR1, NTH1, XF1, FR1, TH1, SP2, NFR2, NTH2, XF2, FR2, TH2, NSP, NDST, NDSE, FTL)
Convert a set of spectra to a new spectral grid.
integer, dimension(:,:), allocatable allprc
ALLPRC.
Has only the ghost nodes assign to a neighbor domain.
integer, parameter smctype
integer, dimension(:), allocatable eqlsta
EQLSTA.
real, dimension(:), pointer sig2
integer, parameter mtag0
MTAG0.
subroutine strace(IENT, SNAME)
subroutine wmsetm(IMOD, NDSE, NDST)
Select one of the WAVEWATCH III grids / models.
real, dimension(:,:), pointer abpi0
integer, parameter mtag1
MTAG1.
subroutine init_get_jsea_isproc(ISEA, JSEA, ISPROC)
Set JSEA for all schemes.
Define data structures to set up wave model dynamic data for several models simultaneously.
subroutine extcde(IEXIT, UNIT, MSG, FILE, LINE, COMM)
type(bpst), dimension(:,:), allocatable, target bpstge
BPSTGE.
type(output), dimension(:), allocatable, target outpts
Parallel routines for implicit solver.
subroutine init_get_isea(ISEA, JSEA)
Set ISEA for all schemes.
integer mpi_comm_mwave
MPI_COMM_MWAVE.