Ignore:
Timestamp:
Dec 17, 2025, 7:33:39 PM (5 weeks ago)
Author:
yann meurdesoif
Message:

Separate pbl_surface into 3 subroutines for GPU port

pbl_surface_uncompress_pre : prepare computation for sub subsurface before compressing
pbl_surface_subsrf : each sub-surface is called one after other (horizontal = knon)
pbl_surface_uncompress_post : sub-surface are uncompressed, computation is done on whole domain (horizontal = klon)

pbl_surface_main becomes the driver, calling pbl_surface_uncompress_pre, and then looping under sub-surface (and calling pbl_surface_subsrf) and then calling pbl_surface_uncompress_post.

merge of commit r5868

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/trunk/libf/phylmd/soil.f90

    r5298 r5942  
    6666  REAL, INTENT(IN)                     :: ptimestep
    6767  INTEGER, INTENT(IN)                  :: indice, knon !, knindex
    68   REAL, DIMENSION(klon), INTENT(IN)    :: snow
    69   REAL, DIMENSION(klon), INTENT(IN)    :: ptsrf
    70   REAL, DIMENSION(klon), INTENT(IN)    :: qsol
    71   REAL, DIMENSION(klon), INTENT(IN)    :: lon
    72   REAL, DIMENSION(klon), INTENT(IN)    :: lat
    73 
    74   REAL, DIMENSION(klon,nsoilmx), INTENT(INOUT) :: ptsoil
    75   REAL, DIMENSION(klon), INTENT(OUT)           :: pcapcal
    76   REAL, DIMENSION(klon), INTENT(OUT)           :: pfluxgrd
     68  REAL, DIMENSION(knon), INTENT(IN)    :: snow
     69  REAL, DIMENSION(knon), INTENT(IN)    :: ptsrf
     70  REAL, DIMENSION(knon), INTENT(IN)    :: qsol
     71  REAL, DIMENSION(knon), INTENT(IN)    :: lon
     72  REAL, DIMENSION(knon), INTENT(IN)    :: lat
     73
     74  REAL, DIMENSION(knon,nsoilmx), INTENT(INOUT) :: ptsoil
     75  REAL, DIMENSION(knon), INTENT(OUT)           :: pcapcal
     76  REAL, DIMENSION(knon), INTENT(OUT)           :: pfluxgrd
    7777
    7878!-----------------------------------------------------------------------
     
    8383  REAL, DIMENSION(nsoilmx)            :: zdz2
    8484  REAL                                :: z1s
    85   REAL, DIMENSION(klon)               :: ztherm_i
    86   REAL, DIMENSION(klon,nsoilmx,nbsrf) :: C_coef, D_coef
     85  REAL, DIMENSION(knon)               :: ztherm_i
     86  REAL, DIMENSION(knon,nsoilmx,nbsrf) :: C_coef, D_coef
    8787
    8888! Local saved variables
Note: See TracChangeset for help on using the changeset viewer.