Ignore:
Timestamp:
Jan 11, 2013, 10:19:19 AM (11 years ago)
Author:
Laurent Fairhead
Message:

Version testing basée sur la r1706


Testing release based on r1706

Location:
LMDZ5/branches/testing
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • LMDZ5/branches/testing

  • LMDZ5/branches/testing/libf/dyn3dmem/parallel.F90

    r1669 r1707  
    11!
    2 ! $Id: parallel.F90 1279 2009-12-10 09:02:56Z fairhead $
     2! $Id$
    33!
    44  module parallel
     
    9494      integer, dimension(3) :: blocklen,type
    9595      integer :: comp_id
    96 
     96      character(len=4)  :: num
     97      character(len=20) :: filename
     98 
    9799#ifdef CPP_OMP   
    98100      INTEGER :: OMP_GET_NUM_THREADS
     
    126128        mpi_rank=0
    127129      ENDIF
    128  
     130
     131
     132! Open text output file with mpi_rank in suffix of file name
     133      IF (lunout /= 5 .and. lunout /= 6) THEN
     134         WRITE(num,'(I4.4)') mpi_rank
     135         filename='lmdz.out_'//num
     136         IF (mpi_rank .NE. 0) THEN
     137            OPEN(UNIT=lunout,FILE=TRIM(filename),ACTION='write', &
     138               STATUS='unknown',FORM='formatted',IOSTAT=ierr)
     139         ENDIF
     140      ENDIF
     141
    129142     
    130143      allocate(jj_begin_para(0:mpi_size-1))
     
    376389      integer :: ierr
    377390      integer :: i
    378       deallocate(jj_begin_para)
    379       deallocate(jj_end_para)
    380       deallocate(jj_nb_para)
     391
     392      if (allocated(jj_begin_para)) deallocate(jj_begin_para)
     393      if (allocated(jj_end_para))   deallocate(jj_end_para)
     394      if (allocated(jj_nb_para))    deallocate(jj_nb_para)
    381395
    382396      if (type_ocean == 'couple') then
     
    643657          enddo
    644658         
    645         endif
     659        else
     660          ! Ehouarn: When in debug mode, ifort complains (for call MPI_GATHERV
     661          !          below) about Buffer_Recv() being not allocated.
     662          !          So make a dummy allocation.
     663          allocate(Buffer_Recv(1))
     664        endif ! of if (MPI_Rank==rank)
    646665 
    647666!$OMP CRITICAL (MPI)
     
    717736       
    718737   
    719     /* 
    720   Subroutine verif_hallo(Field,ij,ll,up,down)
    721     implicit none
    722 #include "dimensions.h"
    723 #include "paramet.h"   
    724     include 'mpif.h'
    725    
    726       INTEGER :: ij,ll
    727       REAL, dimension(ij,ll) :: Field
    728       INTEGER :: up,down
    729      
    730       REAL,dimension(ij,ll): NewField
    731      
    732       NewField=0
    733      
    734       ijb=ij_begin
    735       ije=ij_end
    736       if (pole_nord)
    737       NewField(ij_be       
    738 */
     738!  Subroutine verif_hallo(Field,ij,ll,up,down)
     739!    implicit none
     740!#include "dimensions.h"
     741!#include "paramet.h"   
     742!    include 'mpif.h'
     743!   
     744!      INTEGER :: ij,ll
     745!      REAL, dimension(ij,ll) :: Field
     746!      INTEGER :: up,down
     747!     
     748!      REAL,dimension(ij,ll): NewField
     749!     
     750!      NewField=0
     751!     
     752!      ijb=ij_begin
     753!      ije=ij_end
     754!      if (pole_nord)
     755!      NewField(ij_be       
     756
    739757  end module parallel
Note: See TracChangeset for help on using the changeset viewer.