diff --git a/src/MNH/tke_eps_sources.f90 b/src/MNH/tke_eps_sources.f90 index b9c038e697c516180e60442cf01585aaf9fa8f17..cb75d7da41b619540ae1c5afbf27610ae675bbf9 100644 --- a/src/MNH/tke_eps_sources.f90 +++ b/src/MNH/tke_eps_sources.f90 @@ -418,7 +418,7 @@ ZA(:,:,:) = - PTSTEP * XCET * & #else CALL MZM_DEVICE(ZKEFF, ZTMP1_DEVICE) !Warning: re-used later CALL MZM_DEVICE(PRHODJ,ZTMP2_DEVICE) !Warning: re-used later -!$acc kernels +!$acc kernels present(ZA) #ifndef MNH_BITREP ZA(:,:,:) = - PTSTEP * XCET * ZTMP1_DEVICE(:,:,:) * ZTMP2_DEVICE(:,:,:) / PDZZ(:,:,:)**2 #else @@ -544,14 +544,16 @@ end if if (lbudget_tke) then !Store the previous source terms in prtkes before initializing the next one - PRTKES(:,:,:) = PRTKES(:,:,:) + PRHODJ(:,:,:) * & + !$acc kernels + PRTKES(:,:,:) = PRTKES(:,:,:) + PRHODJ(:,:,:) * & ( PDP(:,:,:) + PTP(:,:,:) & - XCED * SQRT(PTKEM(:,:,:)) / PLEPS(:,:,:) * ( PEXPL*PTKEM(:,:,:) + PIMPL*ZRES(:,:,:) ) ) - + !$acc end kernels call Budget_store_init( tbudgets(NBUDGET_TKE), 'TR', prtkes(:, :, :) ) end if !$acc kernels +!dir$ concurrent PRTKES(:,:,:) = ZRES(:,:,:) * PRHODJ(:,:,:) / PTSTEP - PRTKESM(:,:,:) !$acc end kernels ! @@ -566,6 +568,7 @@ if (lbudget_tke) call Budget_store_end( tbudgets(NBUDGET_TKE), 'TR', prtkes(:, : ! !$acc kernels #ifndef MNH_BITREP +!dir$ concurrent PRTHLS(:,:,:) = PRTHLS(:,:,:) + XCED * SQRT(PTKEM(:,:,:)) / PLEPS(:,:,:) * & #else PRTHLS(:,:,:) = PRTHLS(:,:,:) + XCED * BR_POW(PTKEM(:,:,:),0.5) / PLEPS(:,:,:) * &