From 43f0ea57655ab5d46f7b85f4a43b43161519df79 Mon Sep 17 00:00:00 2001 From: Juan Escobar <juan.escobar@aero.obs-mip.fr> Date: Thu, 21 Oct 2021 11:29:36 +0200 Subject: [PATCH] Juan 21/10/2021:ZSOLVER/ppm.f90, For GPU , use local pointer for HALO2 --- src/ZSOLVER/ppm.f90 | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/ZSOLVER/ppm.f90 b/src/ZSOLVER/ppm.f90 index 150ef055a..6c80487d4 100644 --- a/src/ZSOLVER/ppm.f90 +++ b/src/ZSOLVER/ppm.f90 @@ -2760,6 +2760,9 @@ REAL, DIMENSION(:,:) :: ZPSRC_HALO2_WEST TYPE(HALO2LIST_ll), SAVE , POINTER :: TZ_PSRC_HALO2_ll ! halo2 for PSRC LOGICAL, SAVE :: GFIRST_CALL_PPM_S0_X = .TRUE. +! +REAL , POINTER , CONTIGUOUS , DIMENSION(:,:) :: ZWEST + !------------------------------------------------------------------------------- !$acc data present( PSRC, PCR, PRHO, PR , & @@ -2800,8 +2803,9 @@ IF (GFIRST_CALL_PPM_S0_X) THEN CALL INIT_HALO2_ll(TZ_PSRC_HALO2_ll,1,IIU,IJU,IKU) END IF CALL GET_HALO2_DF(PSRC, TZ_PSRC_HALO2_ll, HNAME='PSRC') +ZWEST => TZ_PSRC_HALO2_ll%HALO2%WEST !$acc kernels -ZPSRC_HALO2_WEST(:,:) = TZ_PSRC_HALO2_ll%HALO2%WEST(:,:) +ZPSRC_HALO2_WEST(:,:) = ZWEST(:,:) ZPHAT=PSRC ZFPOS=PSRC ZFNEG=PSRC @@ -3211,6 +3215,8 @@ INTEGER :: I,J,K REAL, DIMENSION(:,:) :: ZPSRC_HALO2_SOUTH #endif ! +REAL , POINTER , CONTIGUOUS , DIMENSION(:,:) :: ZSOUTH +! !------------------------------------------------------------------------------- !$acc data present( PSRC, PCR, PRHO, PR , & @@ -3258,12 +3264,13 @@ IF (GFIRST_CALL_PPM_S0_Y) THEN NULLIFY(TZ_PSRC_HALO2_ll) CALL INIT_HALO2_ll(TZ_PSRC_HALO2_ll,1,IIU,IJU,IKU) END IF -CALL GET_HALO2_DF(PSRC, TZ_PSRC_HALO2_ll, HNAME='PSRC') +CALL GET_HALO2_DF(PSRC, TZ_PSRC_HALO2_ll, HNAME='PSRC') +ZSOUTH => TZ_PSRC_HALO2_ll%HALO2%SOUTH(:,:) ! ! Initialize with relalistic value all work array ! !$acc kernels -ZPSRC_HALO2_SOUTH(:,:) = TZ_PSRC_HALO2_ll%HALO2%SOUTH(:,:) +ZPSRC_HALO2_SOUTH(:,:) = ZSOUTH(:,:) ZPHAT=PSRC ZFPOS=PSRC ZFNEG=PSRC -- GitLab