Changeset 3924


Ignore:
Timestamp:
Oct 6, 2025, 11:58:26 AM (4 weeks ago)
Author:
jmauxion
Message:

Mars PCM:
Fixing revision 3923: adding OMP_THREADPRIVATE to new save variables.
JM

Location:
trunk/LMDZ.MARS
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.MARS/changelog.txt

    r3923 r3924  
    49854985file is opened/closed once, thus saving significant computing time. When true,
    49864986the opening frequency is at output frequency (required in debug mode).
     4987
     4988== 06/09/2025 == JM
     4989Fixing revision 3923: adding OMP_THREADPRIVATE to new save variables.
  • trunk/LMDZ.MARS/libf/phymars/writediagfi.F

    r3923 r3924  
    8383      character(len=27),save :: prevnom='1234567890'
    8484      character(len=27),save :: lastnom='1234567890'
    85 !$OMP THREADPRIVATE(zitau,firstnom)
     85!$OMP THREADPRIVATE(zitau,lastzitau,firstnom,prevnom,lastnom)
    8686
    8787! Ajouts
     
    9090      integer :: idim,varid
    9191      integer, save :: nid
     92!$OMP THREADPRIVATE(nid)
    9293      character(len=*),parameter :: fichnom="diagfi.nc"
    9394      integer, dimension(4) :: id
     
    290291            ! if the very first time to write, open
    291292            if ((nom.eq.firstnom).and.((zitau+1)/isample.eq.1)) then
    292               write(*,*) "Open NETCDF file for firstnom=", firstnom, " and zitau=", zitau
     293              write(*,*) "Open NETCDF file for firstnom=", firstnom
     294              write(*,*) "zitau=", zitau
    293295              ierr=NF_OPEN(fichnom,NF_WRITE,nid) ! open once in all simu
    294296            endif
     
    639641            ! if the very last time to write, close
    640642            if ((nom.eq.lastnom).and.(zitau.eq.lastzitau)) then
    641               write(*,*) "Close NETCDF file for lastnom=",lastnom, "and zitau=", zitau
     643              write(*,*) "Close NETCDF file for lastnom=",lastnom
     644              write(*,*) "zitau=",zitau
    642645              ierr = NF_CLOSE(nid) ! close once in all simu
    643646            endif
Note: See TracChangeset for help on using the changeset viewer.