Changeset 59


Ignore:
Timestamp:
07/31/12 18:39:34 (12 years ago)
Author:
ymipsl
Message:

Correct non compliant operation in MPI_Allreduce

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • codes/icosagcm/trunk/src/dissip_gcm.f90

    r32 r59  
    6161  REAL(rstd),POINTER    :: theta(:) 
    6262  REAL(rstd),POINTER    :: dtheta(:) 
    63   REAL(rstd)            :: dumax 
    64   REAL(rstd)            :: dthetamax 
     63  REAL(rstd)            :: dumax,dumax1 
     64  REAL(rstd)            :: dthetamax,dthetamax1 
    6565  REAL(rstd)            :: r 
    6666  REAL(rstd)            :: tau 
     
    197197      ENDDO 
    198198 
    199       IF (using_mpi) CALL MPI_ALLREDUCE(dumax,dumax,1,MPI_REAL8,MPI_MAX,comm_icosa,ierr) 
    200  
     199      IF (using_mpi) THEN  
     200                          CALL MPI_ALLREDUCE(dumax,dumax1,1,MPI_REAL8,MPI_MAX,comm_icosa,ierr) 
     201        dumax=dumax1 
     202      ENDIF 
     203                         
    201204      DO ind=1,ndomain 
    202205        CALL swap_dimensions(ind) 
     
    267270      ENDDO 
    268271 
    269       IF (using_mpi) CALL MPI_ALLREDUCE(dumax,dumax,1,MPI_REAL8,MPI_MAX,comm_icosa,ierr) 
     272      IF (using_mpi) THEN 
     273        CALL MPI_ALLREDUCE(dumax,dumax1,1,MPI_REAL8,MPI_MAX,comm_icosa,ierr) 
     274        dumax=dumax1 
     275      ENDIF 
    270276       
    271277      DO ind=1,ndomain 
     
    333339        ENDDO 
    334340      ENDDO 
    335       IF (using_mpi) CALL MPI_ALLREDUCE(dthetamax,dthetamax,1,MPI_REAL8,MPI_MAX,comm_icosa,ierr) 
     341      IF (using_mpi) THEN 
     342        CALL MPI_ALLREDUCE(dthetamax,dthetamax1,1,MPI_REAL8,MPI_MAX,comm_icosa,ierr) 
     343        dthetamax=dthetamax1 
     344      ENDIF 
    336345      PRINT *,"divgrad : it :",it ,": dthetamax",dthetamax 
    337346 
Note: See TracChangeset for help on using the changeset viewer.