diff --git a/src/ecwam/cireduce_loki_gpu.F90 b/src/ecwam/cireduce_loki_gpu.F90 index cfcfc002..755588a3 100644 --- a/src/ecwam/cireduce_loki_gpu.F90 +++ b/src/ecwam/cireduce_loki_gpu.F90 @@ -99,12 +99,14 @@ SUBROUTINE CIREDUCE_LOKI_GPU (WVPRPT, FF_NOW) ENDIF CALL GSTATS(1493,0) ! DETERMINE THE WAVE ATTENUATION FACTOR -!$acc parallel loop gang present(FF_NOW, WVPRPT) vector_length(NPROMA_WAM) +!$acc data present(FF_NOW, WVPRPT) + DO ICHNK = 1, NCHNK CALL CIWAF(1, NPROMA_WAM, WVPRPT%CGROUP(:,:,ICHNK), FF_NOW%CICOVER(:,ICHNK), & & FF_NOW%CITHICK(:,ICHNK), WVPRPT%CIWA(:,:,ICHNK)) ENDDO -!$acc end parallel loop + +!$acc end data CALL GSTATS(1493,1) ENDIF diff --git a/src/ecwam/outbs_loki_gpu.F90 b/src/ecwam/outbs_loki_gpu.F90 index f1135e59..9c4720b5 100644 --- a/src/ecwam/outbs_loki_gpu.F90 +++ b/src/ecwam/outbs_loki_gpu.F90 @@ -95,7 +95,8 @@ SUBROUTINE OUTBS_LOKI_GPU (MIJ, FL1, XLLWS, & !$loki update_device CALL GSTATS(1502,0) -!$acc parallel loop gang default(present) copyin(NPROMA_WAM) copyout(BOUT) vector_length(NPROMA_WAM) +!$acc data present(MIJ,WVPRPT,WVENVI,INTFLDS,FF_NOW,NEMO2WAM) copyout(BOUT) + DO ICHNK = 1, NCHNK CALL OUTBLOCK(1, NPROMA_WAM, MIJ(:,ICHNK), & & FL1(:,:,:,ICHNK), XLLWS(:,:,:,ICHNK), & @@ -117,7 +118,8 @@ SUBROUTINE OUTBS_LOKI_GPU (MIJ, FL1, XLLWS, & & NEMO2WAM%NEMOVCUR(:, ICHNK), & & BOUT(:,:,ICHNK)) ENDDO -!$acc end parallel loop + +!$acc end data CALL GSTATS(1502,1) ! PRINT OUT NORMS diff --git a/src/ecwam/wamintgr_loki_gpu.F90 b/src/ecwam/wamintgr_loki_gpu.F90 index 0695abef..705e10e8 100644 --- a/src/ecwam/wamintgr_loki_gpu.F90 +++ b/src/ecwam/wamintgr_loki_gpu.F90 @@ -155,7 +155,8 @@ SUBROUTINE WAMINTGR_LOKI_GPU(CDTPRA, CDATE, CDATEWH, CDTIMP, CDTIMPNEXT, & IF (LHOOK) CALL DR_HOOK('IMPLSCH',0,ZHOOK_HANDLE_IMPLSCH) TIME0=-WAM_USER_CLOCK() -!$acc parallel loop gang vector_length(NPROMA_WAM) default(present) copyin(NPROMA_WAM) +!$acc data present(VARS_4D,WVPRPT,WVENVI,FF_NOW,WAM2NEMO,INTFLDS,MIJ) + DO ICHNK=1,NCHNK CALL IMPLSCH (1, NPROMA_WAM, VARS_4D%FL1(:,:,:,ICHNK), & & WVPRPT%WAVNUM(:,:,ICHNK), WVPRPT%CGROUP(:,:,ICHNK), WVPRPT%CIWA(:,:,ICHNK), & @@ -179,7 +180,8 @@ SUBROUTINE WAMINTGR_LOKI_GPU(CDTPRA, CDATE, CDATEWH, CDTIMP, CDTIMPNEXT, & & INTFLDS%PHIEPS(:,ICHNK), INTFLDS%PHIAW(:,ICHNK), & & MIJ%PTR(:,ICHNK), VARS_4D%XLLWS(:,:,:,ICHNK) ) END DO -!$acc end parallel loop + +!$acc end data TIME_PHYS = TIME_PHYS + (TIME0+WAM_USER_CLOCK())*1.E-06 IF (LHOOK) CALL DR_HOOK('IMPLSCH',1,ZHOOK_HANDLE_IMPLSCH)